1. A relation with two attributes is always in which form? options are
4NF BCNF
5NF DK/NF
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
Can anybody explain following questions from the above interview:
Question:
Output:
int main()
{
char *str = “junk”;
scanf (“%[A telephonic girl]”, str);
printf (“%s\n”, str);
return 0;
}
Question : Data Structure that can be useful for the calculation like ab
there absolutely nothing wrong in your interpretation.
here is a link that might help : http://www.unix.org/whitepapers/64bit.html
On 4 August 2011 11:18, Shashank Jain shashan...@gmail.com wrote:
see dipankar, i hv 64 bit OS nd processor bt i dont know abt the compiler.
nd yeah size of int
man this is too big of a page to go thru...
so tell as both (OS nd pro) are 64 bit why is ptr size 4 bytes?
nd also does it depend on all 3 : OS, processor, compiler ?
Shashank Jain
IIIrd year
Computer Engineering
Delhi College of Engineering
On Thu, Aug 4, 2011 at 11:57 AM, Dipankar Patro
For simple answer: yes.
All must be compatible with 64 bit data/address handling.
On 4 August 2011 12:02, Shashank Jain shashan...@gmail.com wrote:
man this is too big of a page to go thru...
so tell as both (OS nd pro) are 64 bit why is ptr size 4 bytes?
nd also does it depend on all 3 : OS,
@ Ashish:
The function is for rounding off decimal numbers. how is -2 rounded off to
-1?
@Gene:
Unfortunately, I was not selected in the first round itself :(
@ Sagar Pareek:
Thats what I missed, I should searched for the questions before hand to
atleast clear the first round. No wonder the
So if either of the OS , Compiler , Processor are 32 Bit , then the size is
bound to be 4 bytes?
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
The input for the above code was hello world. So the output would be hello.
As the input will stop on reading 'w'.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
Can any one explain the working of %[A telephonnic girl]
*Muthuraj R
IV th Year , ISE
PESIT , Bangalore*
On Thu, Aug 4, 2011 at 12:25 PM, Nitish Garg nitishgarg1...@gmail.comwrote:
The input for the above code was hello world. So the output would be hello.
As the input will stop on reading
actually the questn should go like this.wud that be good
/optimised with space because we can use more storages for a tree
without freeing them
On Thu, Aug 4, 2011 at 10:09 AM, rajeev bharshetty rajeevr...@gmail.com wrote:
Since you are maintaining two different data structures ,one for
bit twiddling hacks, a stanford resource.
http://graphics.stanford.edu/~seander/bithacks.html
On Aug 4, 10:55 am, Shashank Jain shashan...@gmail.com wrote:
even this is a gud
1.http://www.cprogramming.com/tutorial/bitwise_operators.html
Shashank Jain
IIIrd year
Computer Engineering
Delhi
its a regex. scanf will only accept characters in square brackets.
On Thu, Aug 4, 2011 at 12:45 PM, muthu raj muthura...@gmail.com wrote:
Can any one explain the working of %[A telephonnic girl]
*Muthuraj R
IV th Year , ISE
PESIT , Bangalore*
On Thu, Aug 4, 2011 at 12:25 PM, Nitish
BCNF
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at
yeah bcnf
On Thu, Aug 4, 2011 at 1:06 PM, ankit sambyal ankitsamb...@gmail.comwrote:
BCNF
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group,
see first its performing the operation (-2+0.5) so the ans is -1.5 and then
its rounding off.. the final ans is -1.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe
there are 12 black and 12 white socks
p(bb)+p(ww) is what we want...
p(bb)=12/24*11/23
p(ww)=12/24*11/23
so it is just 2*12/24*11/23=11/23
On Wed, Aug 3, 2011 at 9:08 PM, Prakash D cegprak...@gmail.com wrote:
no.. it's really easy to find it out
there are 12 black and 12 white pieces.
I have my google interview at the end of this month.
can any body provide me some tips/suggestions/questions ?
I am sure some of you guys here must have appeared in google interviews
before,
your help will be very valuable and much appreciated.
Thanks
--
You received this message because you
well i reached upto interview
mcq were already told by srinivasan
then they sort out students in two buckets
1. sys developer
2. sys analyst
i was selected as sys analyst
then they took coding round :-
in sys analyst they gave a log file having eppoch time stamp enclode in [ ]
. u have to
I dont know , but the double function question was highly ambigous one. They
were satified by my arguements whie giving written test and asked me write
explaintation down but still they went on to deduct two marks. Kaafi strange
tha..
On Thu, Aug 4, 2011 at 1:33 PM, Nathiya Perumal
whats the priority of ^ symbol?
Shashank Jain
IIIrd year
Computer Engineering
Delhi College of Engineering
On Thu, Aug 4, 2011 at 1:52 PM, Arun Vishwanathan aaron.nar...@gmail.comwrote:
there are 12 black and 12 white socks
p(bb)+p(ww) is what we want...
p(bb)=12/24*11/23
someone explain the 3rd question of section 2 related to the datastructure
--
Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
On Thu, Aug 4, 2011 at 1:42 AM, Ankur Khurana ankur.kkhur...@gmail.comwrote:
I dont know , but the double function question was
@poised
yeah
On Thu, Aug 4, 2011 at 2:18 PM, Amol Sharma amolsharm...@gmail.com wrote:
someone explain the 3rd question of section 2 related to the datastructure
--
Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
On Thu, Aug 4, 2011 at 1:42 AM, Ankur
can u explain ???
On Thu, Aug 4, 2011 at 1:19 PM, aman jain amanjain@gmail.com wrote:
yeah bcnf
On Thu, Aug 4, 2011 at 1:06 PM, ankit sambyal ankitsamb...@gmail.comwrote:
BCNF
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To
becoz , Consider two Attributes, A B
then possibility are, 1)AB is a key then directly in BCNF,
2)A is a key then automaticaly B is depend on A
3)vice versa of 2)
so
A relation with two attributes is always 2Nf,3nf and also in BCNF form.
Vijay
On Thu, Aug 4, 2011 at 2:51 PM,
h nikhil how are you
On Thu, Aug 4, 2011 at 3:57 PM, Nikhil Gupta nikhilgupta2...@gmail.comwrote:
You have 2 identical ropes that burn in 1 hour (with non-uniform rate).
How will you measure 45 minutes using them?
--
Nikhil Gupta
Senior Co-ordinator, Publicity
CSI, NSIT Students'
Lit the first rope on both the ends and simultaneously lit the second rope
on one end.
Now first rope will take 30mins to burn completely, and by that time second
rope is half burnt.
then lit the second end of 2nd rope which will burn for 15mins
so altogerther u can measure 45 mins
On Thu, Aug 4,
@priyanka, the ropes have a non uniform rate of burning. Means at some
duration they will be burning faster, and slower at some. So you cannot say
that first rope will take 30mins to burn completely, and by that time
second rope is half burnt.
Nikhil Gupta
--
You received this message
-- Forwarded message --
From: jestincobol nair jestinco...@gmail.com
Date: Thu, Aug 4, 2011 at 4:33 PM
Subject: Solve dis!
*Three beauty pageant finalists-Cindy, Amy and Linda-The winner was
musician. The one who was not last or first was a math major. The one who
came in third
When the first rope is completely burnt after 30 minutes, the length of rope
2 remaining would be such that it would burn completely in the next 30
minutes, so if at this moment the rope 2 is lit at other end also, it will
burn completely in 15 min more, thereby giving a time of 45 min.
--
both ropes have to burn in one hour.. so if burn first rope at both ends it
wil definitely take 30 mins to burn completely no matter how non uniform
burning is.. when first rope burn out completly(after 30 mins) second rope
still have 30 mins left for complete burning so if it is burn at both
hey can any1 post me where i can find source to prepare for netapp.
thanks in advance
naveen
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this
Hi All,
In the code below, even though pD is actually pointing to a base
class object, how is the print function being successfully called?
#includeiostream
class base
{
public:
int BVal;
base()
{
BVal = 100;
}
};
class derived : public base
{
public:
Calibrate both the ropes and burn 1 rope from both ends. It will take half
an hour. Then note down the point where the rope fully burns out. Cut the
second rope at this point and fire both ends of any one of the pieces. This
will take 15 mins.
On Thu, Aug 4, 2011 at 4:54 PM, anubhav gupta
@Nikhil : This question was asked to 2 people during Adobe interview on
Tuesdaythe above solutions are perfectly alright.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
1. i am not sure abt cindy or linda...
2. tuesday
On Thu, Aug 4, 2011 at 4:41 PM, jestincobol nair jestinco...@gmail.comwrote:
-- Forwarded message --
From: jestincobol nair jestinco...@gmail.com
Date: Thu, Aug 4, 2011 at 4:33 PM
Subject: Solve dis!
*Three beauty
^ it is cindy
1-cindy
2-linda
3-amy
On Thu, Aug 4, 2011 at 5:18 PM, sagar pareek sagarpar...@gmail.com wrote:
1. i am not sure abt cindy or linda...
2. tuesday
On Thu, Aug 4, 2011 at 4:41 PM, jestincobol nair jestinco...@gmail.comwrote:
-- Forwarded message --
From:
@shady why cindy not linda?
On Thu, Aug 4, 2011 at 5:21 PM, shady sinv...@gmail.com wrote:
^ it is cindy
1-cindy
2-linda
3-amy
On Thu, Aug 4, 2011 at 5:18 PM, sagar pareek sagarpar...@gmail.comwrote:
1. i am not sure abt cindy or linda...
2. tuesday
On Thu, Aug 4, 2011 at 4:41 PM,
@Amit: It is given that the array is decreasing, then increasing. An
array of constants is neither increasing nor decreasing.
Dave
On Aug 3, 11:41 pm, amit karmakar amit.codenam...@gmail.com wrote:
Can you show how to find k for an array containing n 2's using binary
search.
On Aug 4, 6:29
@Kartik: k can be found with a binary search. Once k is known, the key
can be found with one or two binary searches. O(log n).
Dave
On Aug 3, 11:08 pm, kartik sachan kartik.sac...@gmail.com wrote:
if k is known to us the searching can be done in log(n) time
if k is not known to us ,we first
@Tushar: Either value of k will work. You are going to search both
sides of k.
Dave
On Aug 3, 10:59 pm, Tushar Bindal tushicom...@gmail.com wrote:
if we do not know k, how do we find it?
inthe series : 17 15 13 11 9 1 3 5 7
we can take k at element 1 also as the descending series can be 17
*// Using friend functions to overload addition and subtarction operators*
#include iostream.h
class myclass
{
int a;
int b;
public:
myclass(){}
myclass(int x,int y){a=x;b=y;}
void show()
{
coutaendlbendl;
}
*// these are friend operator functions
// NOTE: Both the operans will be be passed
Problem 2 can be solved in O(n/k).
If you want to search for x, look at the first element. If the element
is not found, find the difference between the current element and x,
let this be stored in diff. Now, x will be atleast diff number of
positions ahead in the array. So, the next position is
@amit it's given that array is increasing then decreasing..so where
there is change from incre to drece that value of i in loop will be k
in this we can find out k if not given
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post
Ya, Tuesday is right. Quiet simple
On Sunday both should say truth. If only one guy says it is sunday it should
be a lie.
So the answer should be Tuesday only.
On Thu, Aug 4, 2011 at 5:24 PM, sagar pareek sagarpar...@gmail.com wrote:
@shady why cindy not linda?
On Thu, Aug 4, 2011 at 5:21
@shady : logic for selecting cindy ??
And yes Tuesday is obvious :)
On Thu, Aug 4, 2011 at 5:47 PM, mithun bs mithun...@gmail.com wrote:
Ya, Tuesday is right. Quiet simple
On Sunday both should say truth. If only one guy says it is sunday it
should be a lie.
So the answer should be
@ Nathiya: My statement was a question to whether the function is working or
not. I know how -2 in converted to -1 :P
@ All: The question is actually to tell whether the function mentioned will
work for rounding off or not.
The answer is half the times. It doesn't work for negative numbers.
@
@Grapher: Please look at that post carefully. The code given generates the
next lexicographical permutation - which is exactly what you want.
--
DK
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
Well acc to me the solution should be light the frst one on both ends(half
an hr)After rope one is completely burnt, fr the second one fold the rope in
the middle and then light it from both ends.it will take 15 minstotal 45
mins...please let me know if thr is any flaw in this
On Thu, Aug
If you guys see the question properly it says,
char *str = junk;
str points to a read only memory and can't be written over with any method.
Since there is no change in str. Hence the output will be junk,
irrespective of any input.
regex has been properly explained as above.
--
You received
okie...can someone do it in O(n) space...bt time shld be linear only
On Thu, Aug 4, 2011 at 2:13 AM, Prakash D cegprak...@gmail.com wrote:
O(1) space is t hard for this task
On Thu, Aug 4, 2011 at 12:55 AM, payel roy smithpa...@gmail.com wrote:
Is there any solution for the above?
apologies, both cindy or linda could be first... cindy was satisfying
constraints so i answered that...
On Thu, Aug 4, 2011 at 5:59 PM, jestincobol nair jestinco...@gmail.comwrote:
@shady : logic for selecting cindy ??
And yes Tuesday is obvious :)
On Thu, Aug 4, 2011 at 5:47 PM, mithun
oh ok thanks :)
On Thu, Aug 4, 2011 at 6:29 PM, shady sinv...@gmail.com wrote:
apologies, both cindy or linda could be first... cindy was satisfying
constraints so i answered that...
On Thu, Aug 4, 2011 at 5:59 PM, jestincobol nair jestinco...@gmail.comwrote:
@shady : logic for selecting
Hi Akshay You May Like it http://shashank7s.blogspot.com/
Thanks
Shashank Mani
Computer Science
Birla Institute of Technology Meara
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
@poised: Since it is read only memory junk will be the output if and only if
we enter any string containing characters not inside []. If we try
entering something present within [] i am getting segmentation fault.
*Muthuraj R
IV th Year , ISE
PESIT , Bangalore*
On Thu, Aug 4, 2011 at
thank you Shashank navneet
- Samba
On Thu, Aug 4, 2011 at 3:24 AM, Navneet navneetn...@gmail.com wrote:
bit twiddling hacks, a stanford resource.
http://graphics.stanford.edu/~seander/bithacks.html
On Aug 4, 10:55 am, Shashank Jain shashan...@gmail.com wrote:
even this is a gud 1.
How is the answer for the first q cindy?
On Thu, Aug 4, 2011 at 5:59 PM, jestincobol nair jestinco...@gmail.comwrote:
@shady : logic for selecting cindy ??
And yes Tuesday is obvious :)
On Thu, Aug 4, 2011 at 5:47 PM, mithun bs mithun...@gmail.com wrote:
Ya, Tuesday is right. Quiet
This was the actual statement in the question :
*char *str;*
*strcpy(str,junk);*
scanf(%[A telephonic girl],str);
printf(%s,str);
And the input was - hello world! .
So , the output should be - hello.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks
Cos Linda and Amy are eliminated jus by seein d given conditions
On Thu, Aug 4, 2011 at 6:57 PM, priya v pria@gmail.com wrote:
How is the answer for the first q cindy?
On Thu, Aug 4, 2011 at 5:59 PM, jestincobol nair jestinco...@gmail.comwrote:
@shady : logic for selecting cindy ??
Arvind,
By which condition are you eliminating Linda?
On Thu, Aug 4, 2011 at 6:59 PM, arvind kumar arvindk...@gmail.com wrote:
Cos Linda and Amy are eliminated jus by seein d given conditions
On Thu, Aug 4, 2011 at 6:57 PM, priya v pria@gmail.com wrote:
How is the answer for the first
I got this as my answer-
First place- Cindy or Linda
Second Place- C or L or A
Third place- C or A
How is it possible to eliminate any other possibility. Any condition
missing?
On Thu, Aug 4, 2011 at 7:02 PM, mithun bs mithun...@gmail.com wrote:
Arvind,
By which condition are you eliminating
Yeah.
On 4 August 2011 12:14, N1teesh nitee...@gmail.com wrote:
So if either of the OS , Compiler , Processor are 32 Bit , then the size is
bound to be 4 bytes?
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on
Also, you must remember that 64 OS can never run 32 bit Processors, since it
will require a 64 bit CPU to produce a 64bit address format
On 4 August 2011 19:19, Dipankar Patro dip10c...@gmail.com wrote:
Yeah.
On 4 August 2011 12:14, N1teesh nitee...@gmail.com wrote:
So if either of the OS ,
@saurabh: see this case
input 100, 1, 1, 1,1
your algo -
group 1 - 100
group 2 - 1 1 1 1
but the group with 2 equal strength can be formed as
G1 - 1 1
G2 - 1 1 or 1 1 each...
i mean it is not necessary to take all the people.but your algo takes
the the person with max strength at
Just check if you have installed DEV Cpp win32 installation or not.That will
confirm the usage and observation.As per the Dev cpp page it is available in
32 bit exe only.
On Thu, Aug 4, 2011 at 7:21 PM, Dipankar Patro dip10c...@gmail.com wrote:
Also, you must remember that 64 OS can never run
Hence shown never play cricket when someone in the group is stronger than
the whole team together,,,:D
Anyways my original solution was not taking into account that players can be
excluded.(Thats unfair in a real scenario ryt?)
Its a classical 0/1 knapsack problem which can be implemented either
Hi
Can any1 suggest some good book/website to learn pointers,and
stacks,queues etc..in depth.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send
On Thu, Aug 4, 2011 at 7:37 PM, saurabh singh saurab...@gmail.com wrote:
Its a classical 0/1 knapsack problem which can be implemented either as a
greedy solution or dp
It has been stated earlier in the thread that this is an 'NP-Complete'
problem. [0]
It means, there is no known
amazon will be visiting our campus within few days
any ideas about their pattern especially their online test
the questions asked by them and where they have visited recently for
campus placement
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
On Thu, Aug 4, 2011 at 7:42 PM, Gaurav Menghani
gaurav.mengh...@gmail.com wrote:
On Thu, Aug 4, 2011 at 7:37 PM, saurabh singh saurab...@gmail.com wrote:
Its a classical 0/1 knapsack problem which can be implemented either as a
greedy solution or dp
It has been stated earlier in the
@gaurav: agree...greedy wouldn't work in this case..even 0-1 knapsack is
a DP problem...which can't be done by greedy !!
--
Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
On Thu, Aug 4, 2011 at 7:46 PM, Gaurav Menghani
gaurav.mengh...@gmail.comwrote:
On
@amol knapsack is originaly a greedy problem onlyThe spirit remains
the same,selecting the best at each stepDp helps in defining the best in
the particular case.
@Gaurav I think its NP complete once the number of teams become
varaible,
corrct me if wrong i am weak with the
@Dipankar : thanks.i think,this is the right logic
On Thu, Aug 4, 2011 at 11:10 AM, Dipankar Patro dip10c...@gmail.com wrote:
Well I think the reason is very simple:
When you enter the loop through L, the value of i is not initialized to 0,
it is some garbage value.
now while
On Thu, Aug 4, 2011 at 8:13 PM, saurabh singh saurab...@gmail.com wrote:
think its NP complete once the number of teams become varaible,
corrct me if wrong i am weak with the theoritical stuffs...
Err, it is NP-complete, the thing is when the set of integers is small, a DP
solution runs
Kashish,
I think it won't work.
The correct is:
ls -R | grep .java
On 4 August 2011 20:17, kashish jain kashish.jain.n...@gmail.com wrote:
answer to shell command is
grep -r *.java
i wanted to ask , am i right ?
On Thu, Aug 4, 2011 at 2:16 PM, Shashank Jain shashan...@gmail.comwrote:
What happens when a thread calls exec ?? What happens to the other threads
of the same process ??
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group,
ls -R *.java
On Thu, Aug 4, 2011 at 8:26 PM, Dipankar Patro dip10c...@gmail.com wrote:
Kashish,
I think it won't work.
The correct is:
ls -R | grep .java
On 4 August 2011 20:17, kashish jain kashish.jain.n...@gmail.com wrote:
answer to shell command is
grep -r *.java
i wanted to ask
I think the answer would be the thread calling execute will have to wait for
the executed command to exit and then it will proceed.
As for other threads, they shouldn't be affected.
Please do correct me if it is wrong.
On 4 August 2011 20:27, ankit sambyal ankitsamb...@gmail.com wrote:
What
You are welcome Tushar.
My suggestion is always to print the value of iter (i in this case) in a
loop if you think there is something wrong. Helps 99% of times.
On 4 August 2011 20:13, Tushar Kanta Rath tusharkanta.r...@gmail.comwrote:
@Dipankar : thanks.i think,this is the right
i think for
pointers:- yashwant kanetkar(Understanding pointers in C) will be good
enough.
Queues, Stacks: Tanenbaum(Data Structures through C/C++)
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
#includestdio.h
#includeconio.h
void main()
{
clrscr();
float a=5.375;
char *p;
int i;
p=(char *)a;
for(i=0;i=3;i++)
printf(%02x,(unsigned char)p[i]);
getch();
}
O/P-00 00 AC 40
Plz anyone explain me output.
Vijay
--
You received this message because you are subscribed to the
@Dipankar: But all the threads of a process share code and data section. So,
how is it possible that they are not affected ???
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To
@ Muthu raj:
My bad, didn't check it properly. It is surely a runtime error.
@ Niteesh Mehra:
That code is even more wrong.
without assigning any memory to str, how will you copy anything into it?
This will definitely be a runtime error.
http://ideone.com/erEXf
--
You received this message
Good point.
Let me search a bit on Threads. Will get back asap.
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
https://groups.google.com/d/msg/algogeeks/-/7pWIqcdwugcJ.
To post to this group, send
+1 to 11/23 in probability question
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
https://groups.google.com/d/msg/algogeeks/-/IVQqcq_D5RsJ.
To post to this group, send email to
original knapsack is called fractional knapsack in which greedy works...but
we were talking abt 0-1 knapsack :P
--
Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
On Thu, Aug 4, 2011 at 8:19 PM, Gaurav Menghani
gaurav.mengh...@gmail.comwrote:
On Thu, Aug
thiis is theexact thing i thought abt segmentation error...but it is again
system-dependent...if u wud try this on 7 or vista or XP...which are high
on resources it wont give error to that...but there is definately an error
in code...
but y do u think tht junk wont be overwritten? s is simply a
I told you the spirit is greedy backed up by DP for creating correct optimal
substructuresA pure greedy solution wont create the right
substructure...
On Thu, Aug 4, 2011 at 9:06 PM, Amol Sharma amolsharm...@gmail.com wrote:
original knapsack is called fractional knapsack in which greedy
the thing wrong with 1 is it doesnt return any value...main if not
explicitly declared is of type int hence main shud return some value...
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To view this discussion on the web visit
given an array containing +ve n -ve numbers , can someone give
efficient algo to find the max cont subarray product.
this is same as problem http://online-judge.uva.es/p/v110/11059.html.
here is the code for this one:
#include cstdio
#include iostream
#include algorithm
#include limits.h
using
okay,thanks a lot:)
On Thu, Aug 4, 2011 at 8:46 PM, abhishek kumar
mailatabhishekgu...@gmail.com wrote:
i think for
pointers:- yashwant kanetkar(Understanding pointers in C) will be good
enough.
Queues, Stacks: Tanenbaum(Data Structures through C/C++)
--
You received this message because
floating point numbers are stored in 4 bytes with first 3 bytes storing the
mantissa part...1st bit of last byte stores the sign of mantissa... rest of
the bits store the magnitude of the exponent relative to +127( exponent +
127 wll be stored). Now ur num will be stored as 5375 in first 3
@Aditi: The ropes burn at non-uniform rates. So for your solution, you
would have to fold it in half according to time, not according to
length. But you don't know where the half-hour point is unless you
light one end of the second rope at the same time you light both ends
of the first rope. When
As some have said, this is NP, so for larger values of N it takes a
very long time. For N=20 it runs quite quickly.
// True if some set of strengths from s[n] sum to t
bool divide(unsigned int *s, int n, int t)
{
if (t == 0) return true; // We reached the goal
if (n
To elaborate more. New process image will not have the existing threads and
user defined data declared in current process will be wiped out. Parent can
do is to wait for the child status by calling wait().
for example
main()
{
pid = fork();
if (child) {
exec(ls); ///
@dave...im not burning half of the rope or anything...my idea is jst to
increase the rate of burning..by folding it in the middle and then lighting
it from both ends...im burning the entire rope wid 4 times the rate of
burning...shud take 15 mins
On Thu, Aug 4, 2011 at 9:52 PM, Dave
guys even i m not sure cindy or linda but either of dem is corrrect
On Thu, Aug 4, 2011 at 7:07 PM, priya v pria@gmail.com wrote:
I got this as my answer-
First place- Cindy or Linda
Second Place- C or L or A
Third place- C or A
How is it possible to eliminate any other possibility. Any
The *exec* family of functions shall replace the current process image with
a new process image. It does not matter how many threads you have whole
process gets replaced with new one.
-
Azhar.
On Thu, Aug 4, 2011 at 8:27 PM, ankit sambyal ankitsamb...@gmail.comwrote:
What happens when a
Thanks, but can u elaborate some more explanation, that how for loop is
working here
Vijay
On Thu, Aug 4, 2011 at 9:52 PM, wastrel virmanisadi...@gmail.com wrote:
floating point numbers are stored in 4 bytes with first 3 bytes storing the
mantissa part...1st bit of last byte
Thnks Azhar :)
got the point
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more
find ./ -name *.java
On Thu, Aug 4, 2011 at 8:17 PM, kashish jain kashish.jain.n...@gmail.comwrote:
answer to shell command is
grep -r *.java
i wanted to ask , am i right ?
On Thu, Aug 4, 2011 at 2:16 PM, Shashank Jain shashan...@gmail.comwrote:
whats the priority of ^ symbol?
1 - 100 of 224 matches
Mail list logo