I decided that it's about time to make my contribution to the human kind.
I decided that I had to create something brilliant, that people will use as a reference for quality.
I have a dream that my contribution will help this generation to take science to the next level.
I have a dream that my contribution will help the next generations to understand this world.
Let me introduce you to samanat.com
Showing posts with label programming. Show all posts
Showing posts with label programming. Show all posts
Wednesday, February 08, 2012
Wednesday, May 20, 2009
Does Firefox suck?
I am(was actually) a great fan of Firefox..
From a user's perspective Firefox rocks!
* there are countless add-ons
* it's faster than IE
* it's competing IE (and no one likes Microsoft)
* it had tabs before IE
* it's customizable
But, from a software developer's perspective, Firefox sucks!
* there are much lesser events that IE!
for example, OnPropertyChange, which is triggered as soon as the element is being changed (and not after the change). Lovely event, missing from Firefox.
* there are some events that are partially supported!!
for example, OnKeyPress is supported for input fields, but NOT for tables. According to some people, it's not usable since it's not editable.. However, when you are creating a table that uses navigation arrows, you need this feature to capture the arrow keystrokes.
It seems that Firefox is trying to limit the freedom of the developer either because it will make Firefox slower or because they have decided that some functionality shouldn't be available to developers...
Of course there are solutions, but they are workarounds that shouldn't be needed..
So, bottom line, we should all praise Microsoft! :)
From a user's perspective Firefox rocks!
* there are countless add-ons
* it's faster than IE
* it's competing IE (and no one likes Microsoft)
* it had tabs before IE
* it's customizable
But, from a software developer's perspective, Firefox sucks!
* there are much lesser events that IE!
for example, OnPropertyChange, which is triggered as soon as the element is being changed (and not after the change). Lovely event, missing from Firefox.
* there are some events that are partially supported!!
for example, OnKeyPress is supported for input fields, but NOT for tables. According to some people, it's not usable since it's not editable.. However, when you are creating a table that uses navigation arrows, you need this feature to capture the arrow keystrokes.
It seems that Firefox is trying to limit the freedom of the developer either because it will make Firefox slower or because they have decided that some functionality shouldn't be available to developers...
Of course there are solutions, but they are workarounds that shouldn't be needed..
So, bottom line, we should all praise Microsoft! :)
Friday, April 06, 2007
8 Queens and BBDs (Updated)
As I wrote before, I have finished with my Master Thesis.
I have also defended it.
So, it seems that I have plenty of time to write new posts, to have fun, to go out for beers, etc..
The reality is far from this.. :(
One of the things that keep me occupied these days, is that I am working as a Teacher Assistant at the Efficient Artificial Intelligence Programming course. So, instead of enjoying Easter holidays, I will have to implement this in java.
The problem is well known to the community, and it's about placing 8 queens on a chess board. The queens have to be placed in valid positions (not attacking each other) and the algorithm have to check and show to the user only the positions that will lead to a solution. One way to solve the problem is to use Binary Decision Diagrams. That's how we are going to solve it.
So, I have to create the UI and the Logic of the problem, then hide some code from the Logic and let the students figure out how to implement the missing code..
--Update
Maybe I was not very clear..
The problem is NOT ONLY to restrict the row, column and diagonal of the last inserted queen, but to restrict all the board positions that don't lead to a solution. What I mean by that, could easily be seen at this image. If you place a queen at A5, then E6 should be restricted, because irrespective of where the user will put the other queens, the problem doesn't have a solution.
Brute force cannot help much here, because of the complexity of the problem. We have to calculate the permutations of 8 queens on the 64 positions of the board. That means 64!/(8!*56!) permutations.
Actually, it can be done with brute force, but since the algorithm has to be able to solve the n-queens problem efficiently, there are more efficient algorithms and data structures :)
I have also defended it.
So, it seems that I have plenty of time to write new posts, to have fun, to go out for beers, etc..
The reality is far from this.. :(
One of the things that keep me occupied these days, is that I am working as a Teacher Assistant at the Efficient Artificial Intelligence Programming course. So, instead of enjoying Easter holidays, I will have to implement this in java.
The problem is well known to the community, and it's about placing 8 queens on a chess board. The queens have to be placed in valid positions (not attacking each other) and the algorithm have to check and show to the user only the positions that will lead to a solution. One way to solve the problem is to use Binary Decision Diagrams. That's how we are going to solve it.
So, I have to create the UI and the Logic of the problem, then hide some code from the Logic and let the students figure out how to implement the missing code..
--Update
Maybe I was not very clear..
The problem is NOT ONLY to restrict the row, column and diagonal of the last inserted queen, but to restrict all the board positions that don't lead to a solution. What I mean by that, could easily be seen at this image. If you place a queen at A5, then E6 should be restricted, because irrespective of where the user will put the other queens, the problem doesn't have a solution.
Brute force cannot help much here, because of the complexity of the problem. We have to calculate the permutations of 8 queens on the 64 positions of the board. That means 64!/(8!*56!) permutations.
Actually, it can be done with brute force, but since the algorithm has to be able to solve the n-queens problem efficiently, there are more efficient algorithms and data structures :)
Subscribe to:
Posts (Atom)
