for Begginers ---Profession C++ WROX publications is good...-if u
already know C++use Effective C++ by Scott meyers(too good book)
On 3/16/07, LiveShell <[EMAIL PROTECTED]> wrote:
>
> Hi all,
> Sorry for cross postingCan ny body tell me which is the best
> book for C++ ???
>
>
Hi all,
Sorry for cross postingCan ny body tell me which is the best
book for C++ ???
LiveShell
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email
On 3/15/07, Ravi <[EMAIL PROTECTED]> wrote:
>
> what will be a regular expression(non-UNIX one please) for the set of
> languages which have number of 0s divisible by 5 and number of 1s
> divisible by 2. The set of alphabets is {0,1}.
>
The following is based on `Parallel Regular Expressions'. If
Yes..but in the worst case you could partition the list into 1 and
n-1...we cannot say this deterministically. The average case is O(n)
but worst case would still be O(n^2)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Gro
hi,
This is a very famous question which was asked in my google and yahoo
interviews. There is a very good ole data structure designed for this
purpose called TRIE data structure.
This will solve the problem.
On 2/15/07, aakash mandhar <[EMAIL PROTECTED]> wrote:
>
> And from my experience as an i
well the requirement is only to sort the array
Array repr: 9,6,21,1,7,16,36 (index starting from 1)
Now on sorting the array in place gives: 1,6,7,9,16,21,36
is a perfectly valid answer to the problem.
No one is going to look at the result as a BST, it is going to be
viewed as a sorted array.
If the DFA works then it can be converted to a regular expression
using standard techniques like the one described in
http://www.cs.colostate.edu/~whitley/CS301/L3.pdf
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
A DFA is possible I guess which is interesting, see if the following
DFA works, since the existence of the DFA relates to the existence of
a Regular Expression Describing the language
State/Input 01
q00 q10 q01
q10 q20
You could try the quick-sort algo with these further modifications :
every time you partition the list (assuming ascending) you leave out
the entire working for the right hand part iff the size of the left
hand part is >= m (m is the top m elements that you need). NB : Here
left hand part indicate
I think a regular expression is just too hard, a CFG might be easier . Let
me know if you have a solution for regular expression
On 3/14/07, Ravi <[EMAIL PROTECTED]> wrote:
>
>
> what will be a regular expression(non-UNIXone please) for the set of
> languages which have number of 0s divisible by 5
10 matches
Mail list logo