check it now ... register your team and engage in codewar ..
--
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
How many processes are created in this snippet?
Main()
{
Fork();
Fork() fork () || fork ();
Fork ();
}
--
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
a. 15
b. 19
c. 21
d. 27
e. 31
these are the only options.
--
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
20 is not in option ..so whats the answer??
--
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
thnks everyone...
--
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
1) #include stdio.h
#include stdlib.h
#define SIZEOF(arr) (sizeof(arr)/sizeof(arr[0]))
#define PrintInt(expr) printf(%s:%d\n,#expr,(expr))
int main ()
{
/* The powers of 10 */
int pot[] = {
0001,0010,0100,1000
};
int i;
got it ..!! thnks everyone
--
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
1) #include stdio.h
#define PrintInt(expr) printf(%s : %d\n,#expr,(expr))
int max(int x, int y)
{
(x y) ? return x : return y;
}
int main ()
{
int a = 10, b = 20;
PrintInt(a);
PrintInt(b);
PrintInt(max(a,b));
}
2#include stdio.h
void
This code may also work .give any counter examples...
#includeiostream
using namespace std;
void find_sum(int num,int k,int j,int b);
void display(int i,int j);
#define MAX 8
int res[4]; //array to store
4 numbers..
int arr[MAX]
--
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
there are 5 possibilities ..5th one is_12_..other as specified by
ankit...
t(1) =2 (it can directly jump to anathor bank)
t(2) =3 ( _2_,_1_,_12_)
t(3) =5...
thats how fibonnaci goes on plz correct if wrong...
--
You received this message because you are subscribed to the Google
10
4 5
2 7 6 11
1 39 8 12 13 14 15
i think we should first find the parent of the particular node ..then apply
the concept as told by Brijesh on it
p =parent(q);
r = parent(p);
@muthu raj:
it will also come out ,when loop condition will not be statisfied.i.e when
'p' is not the right child of its parent...in such a case it will not reach
root ..
in the ex given by u it will stop at 4 .
--
You received this message because you are subscribed to the Google Groups
#includestdio.h
#includeconio.h
struct abc
{
char p[1];
};
int main()
{
struct abc *c =NULL;
char name[]=abcde;
c = (struct abc *) malloc (sizeof(struct abc));
strcpy(c-p,name);
printf(%s,c-p);
getch();
return 0;
}
why it is printing the whole string
In c++ we should allocate the memory for the object on the stack or on the
heap? what effect it will have on the program .
--
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
what the reason behind it how do they differ in functonality..?
--
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
can anyone one explain output of question 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 from this group, send email to
hey guys
does anyone know about WINSHUTTLE...its coming to ur campus...
--
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
yes ..u r right ...thnks...
--
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
Given a sorted array of n integers that has been
rotated an unknown number of
times, give an O(log n) algorithm that finds an element in the
array You may assume
that the array was originally sorted in increasing order
EXAMPLE:
but this works ,if array is rotated multiple times ,around different
pivots.
--
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
May be this can work.give any counter example...
int count;
main()
{
int l,rope,cuts;
scanf(%d%d,l,rope);
count =0;
find_cuts(l,rope);
printf(cuts needed is %d,count);
getch();
return 0;
}
int find_cuts(int l,int rope)
{
22 matches
Mail list logo