As my understanding take the input of traffic in time interval then some
all the job and divide them equally to processing unit(assumption
processing unit processing one job in one time units) so interval to time
is varies on the base how much time is taken by the process to assigned
work. One mo
The sequence of price is make more sense if buy price is less than next
value then you can buy even its not the min and next day you can sell all
and
Buy again when min price stock come.
Eg 6, 10, 5, 7, 2,7.
There are many case need to consider the above is the only one scenario.
Other like random
Hi
Anybody do u have c# ebook please send on group
thanks
--
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...@g
hi
anybody do you have CrackCoding ebook pls send .
thanks
--
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...@
int main()
{
int arr[]={1,2,5,1,5,1,1,3,2,2,};
int elements = sizeof(arr)/sizeof(arr[0]);
int count=1;
int num;
sort(arr,arr+elements);
num=arr[0];
for(int i=1;ihttp://groups.google.com/group/algogeeks?hl=en.
Qn. Remove all duplicates words from given a line without using extra memory
?
Ex:-Hello word hello hi
Out put:- Hello word hi
--
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.
T
> 3-Aptitude?
>
>
> On Thu, Aug 4, 2011 at 10:19 AM, Akanksha . wrote:
>
>> In our college they were also looking for the sound fundamentals of header
>> files, libraries, macros etc. So be prepared with these also.
>>
>>
>> On Thu, Aug 4, 2011 at 9:21 AM, um
Better way of using DS, able to write good algo and programming puzzles
Thanks
Umesh
MSIDC hyd
Sent from my Windows Phone
--
From: priya v
Sent: Thursday, August 04, 2011 7:16 AM
To: algogeeks@googlegroups.com
Subject: Re: [algogeeks] Oracle Interview ..Need Help
Order would be O(m*n)...
On Wed, Aug 3, 2011 at 4:01 AM, ankit sambyal wrote:
> Given two lists write a function which returns a list which is the
> intersection of the two lists.the original lists should remain same.
> (Intersection - if first list is say,1,20 3,45 and second list is 3,
Using the all characters of a given String how to specify either
a palindrome or not.
Ex:-
1) String="teste"
After arrange all character we can made a palindrome String as "teset"
So output is TRUE.
2)String="hello"
we can not made a palindrome String
output is FALSE
bool IspalindromePossible (
Are U freshers and How would U scheduled Interview in amazon ??
--
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+unsu
Anybody try for maintain the stable of elements in O(n) as like
Input is :{1,2,3,4,5,6,7}
then Output should be
(2,4,6,1,3,5,7)
not..
{2,4,6,1,5,3,7} base on above discussion ..
--
You received this message because you are subscribed to the Google Groups
"Algorithm G
yes R is actually size of subset that is always less than or equal to Size
of the Array
i.e r<=n
On Thu, Jul 21, 2011 at 11:16 PM, Puneet Gautam wrote:
> @umesh: can R take any value from 1 to 3..?
>
> On 7/22/11, UMESH KUMAR wrote:
> > Hi
> >
> > Given an arr
Hi
Given an array of size N that contain some elements, Write a program for
finding all possible subset of size R .
n
i.e. P
r
Array :[1,2,3,4]
n=4,r=3;
Output should be:
{1,2,3},(1,2,4).{2,3,4},{...} possible 24 sets.
Thanks
--
You r
Hi
Given an array A[], write a function to separate even and odd numbers
(i.e., put all even numbers first than odd numbers) and stability is also
maintain for the elements in the Array.
Eg.
input:
A[] = {12, 34, 45, 9, 8, 90, 3}
output:
A[] = {12, 34, 8, 90, 45, 9, 3}**
Thanks
--
You rec
Hi
@Somnath my question is some different
if given array :3,2,7,10
So according to last discussion Only Out put is *13 *not the show elements
Output :: {3,10}
So basically my question is that how to pick all elements that return max
sum
Thanks..
--
You received this message bec
Hi
Given an array how to find a sequence whose sum is maximum
*but condition is that no two adjacent elements* of the given Array.
ex:- Array:-[3,6,7,10,4]
output:- {6,10}=16
Array::[12,3,5,30]
output:-{12,30}= 42
--
You received this message because you are subscribed to the Google Groups
u can see we r loosing number this is a overflow
same for negative number will produce underflow
Thanks
Umesh
Sent from my Windows Phone
--
From: Supraja Jayakumar
Sent: Tuesday, June 14, 2011 2:28 AM
To: algogeeks@googlegroups.com
Subject: Re: [algogeeks] Swappin
>
>
>>> void call(int a,int b,int c)
>>> {
>>> printf("%d %d %d",a,b,c);
>>> }
>>>
>>> int main()
>>> {
>>> int a=5;
>>> call(a++,a++,++a);
>>> return 0;
>>>
>>> }
>>>
>>>
>>> On Sat, Jun 11, 2011 at 8:21 PM, PRAMENDRA RATHi rathi <
>>> prathi...@gmail.com> wrote:
>>>
IN second progra
If you know link for that book please send for direct Download
On Sat, Apr 23, 2011 at 6:57 AM, D.N.Vishwakarma@IITR wrote:
> *Book can't be send to group as it is more than 4.0 mb . and group can't
> have massage more than 4.0 mb
> *
> On Sat, Apr 23, 2011 at 7:01 PM, UMES
hi.
Do you have anybody C++ by Stroustrup
e-book please send on group.
Thanks and Regards
Umesh kumar
--
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 unsubs
r...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
>
> *-Vishnutej Mylavarapu.*
>
> --
> You received this message because you are subscribed to the Google Groups
> &
gt; 4 -> 4 -> 5
> *
> Now delete node which is next to '*'.
>
>
> On Sun, Mar 13, 2011 at 10:23 PM, UMESH KUMAR wrote:
>
>> hi
>>
>> Given a singly Link list but Head of the List is
>> unknown so my question is that ..
hi
Given a singly Link list but Head of the List is
unknown so my question is that
How to delete a given node from the List???
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send
Hi
my question is without Loop and Recursion function using???
On Fri, Mar 11, 2011 at 5:40 AM, Abhishek Mallick <
abhishek.mallick2...@gmail.com> wrote:
> #include
> int main()
> {
> while(printf("Hello"));
> return 0;
> }
>
> On Thu, Mar 10, 2011 at 11:58 AM, Nishant Agarwal <
> nisha
How to print Hello Infinite times without using
Loop and Recursion function ?
--
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
alg
Hello Everybody
I need right now JSP E-book .
So, Everybody do u have good JSP please send on Group .
Thanks and Regards
Umesh Kumar
D.U.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to
hello...
QN :- How to find *TRANSPOSE* of the *RECTANGULAR* matrix
i,e. m * n , where n != m.
Ex:-
input:-
1 2 3 4
5 6 7 8
output:-
1 5
2 6
3 7
4 8
thanks and regards
UMESH KUMAR
D.U.
--
You
:-
{4,6}, {1,6,3}, {1,2,3,4}
input :-{9,8,7,6};
output:-
No
Thanks And Regards
Umesh Kumar
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, sen
Hello..
Explain and write Algorithm for* Soduo Game* and also describe
Solution is unique or Not.
if Anybody do you have C/C++ code please send to me.
Thanks and Regards
Umesh kumar
--
You received this message because you are subscribed to the Google Groups
main()
> {
>> int a[5]={1,3,6,7,0};
>> int *b;
>> b=&a[2];
>> cout<> }
>>
>> the value of b[-1] is
>> a.1
>> b.3
>> c.-6
>> d.none
>>
>>
ANS will be 3.
Because Compiler internally first converted in the form as *(b-1) , and get
the one position back at the position 3.
--
You received this m
>
> > #define SIZE 10
>>> > int main()
>>> > {
>>> > int arr[SIZE];
>>> > printf("size of array is:%d\n",sizeof(arr));
>>> > return 0;
>>> > }
>>>
>>
when we call the function and pass the name of the ARRAY ,then PUSH the base
Address of the ARRAY in the Stack of t
http://topwebdownloads.com/wp-content/uploads/2009/10/diwali-greetings-2.gif
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send email to
algog
end email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & Regards
Umesh kewat
--
You r
om.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subs
googlegroups.com
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>
algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks"
t; To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & R
es of the triangle with this point
> you will get three small triangle
>
> if ( area(big triangle)== sum of area of small triangles) then the point is
> inside the triangle else it is outside the triangle
>
>
> On Mon, Sep 20, 2010 at 10:02 PM, umesh wrote:
>
>> Initia
ards
Umesh kewat
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more optio
Initially we have given three point A , B, C in plane represent three nodes
of triangle, now given another point Z which lies in same plane, find out
whether that point lies on/inside the triangle or outside of triangletry
to get in min time and space complexity
--
Thanks & Regards
U
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscr
gt; You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more
HI Saurabh,
#include
int main()
{
int A =4;
#define A B
#define B A*3
printf("%d",A);
return 0;
}
Above example will explain ur doubt...
On Fri, Sep 10, 2010 at 9:59 AM, saurabh agrawal wrote:
> @umesh kewat
>
> #include
> int main(){
> int A =4;
>
> #define A
ribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://gro
explain ,if anybody known how to back tracking a Singly link list as a
Doubly list with XOR -operation or any method if implementation of a Doubly
link list using only one pointer .
Explain with help of example
--
You received this message because you are subscribed to the Google Groups
"Algor
On Sat, Aug 14, 2010 at 12:52 PM, AlgoBoy wrote:
> Add two numbers represented in a SLL. Each digit is represented as a
> node...the length of the lists may be more than 2000...
> Wat is the most efficient soln...store the added digits in another
> SLL...and return the head as the answer
>
>
How to convert Singly link list to Doubly link list without converting
the Structure of the list ,so possible or not if possible then explain
soon.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...
how to convert Doubly Link list to a Singly link list without changes
the Structure of the list if possible or not ,if possible then try to discus
of that problem.
thanks and Regards
Umesh kumar
--
You received this message because you are subscribed to the Google Groups
how to sort specific order the given array ,Without using extra memory
Input:-a1,a2,a3,a4,a5..an,b1,b2,b3,b4,b5..bn.
output:-a1,b1,a2,b2,a3,b3,an.bn
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group,
On 8/6/10, Avik Mitra wrote:
>
>
> Do you mean to convert a BST to a HEAP?
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email
@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>
> --
> You
How to decide associativity of the operation on operand
so a simple Ex:-
*ptr++ and ++*ptr
how to work both ?
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.
element. For binary tree we don't follow any rule for creating it.
>
> Data structure for both BST & binary tree: we use a simple structure that
> holds a data value and pointer to its left and right child.
>
>
> On Tue, Aug 3, 2010 at 10:18 AM, UMESH KUMAR wrote:
>
>>
What is the Garbase value in C/C++
and what is the Null pointer ?
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsub
what is the main difference b/w BST and Binary tree for the
purpose of implementation .
and what is the Data structure of that.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
T
On Sun, Aug 1, 2010 at 5:20 PM, Pramod Negi wrote:
> http://pramnegi.blogspot.com/2009/11/dons-permutaion.html
>
> Thanks
> Pramod Negi
>
> On Sun, Aug 1, 2010 at 4:30 PM, UMESH KUMAR wrote:
>
>> Write a C code for generate all possible Permutation
>> as:- 1
Write a C code for generate all possible Permutation
as:- 1 2 3
Total no. of Per=6
also print all permutation
as:- 1 2 3
1 3 2
2 1 3
2 3 1
3 1 2
3 2 1
if inpute is 1 2 3 2
total no of permutation = 12
--
You received this message because you are subscrib
rom this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscribed to the
;> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> Thanks & Regards
>
> Umesh kewat
>
>
subscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscribed to
Qn:-in the given array elements
a1a2a3a4..anb1b2b3b4...bnc1c2c3c4cn
without take a extra memory how to merge just like?
a1b1c1a2b2c2a3b3c3anbncn
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To
Hello everybady,
my question is:-
Find the maximum length Subsequence in the given Array that contains
only 0's and 1's elements and condition is that number of 1;s equal to the
number of 0's.
Ex:-
Input:- 10101011100
output:-101010111000
--
You received this message because you are
Hello .
How to decide insertion sort takes less cost of time
for small input size.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send ema
Hi,
suppose we have given n distinct numbers are a[n].
1. sort them using quick or any other sort in O(nlogn)
2. use then
int find(int *arr, int n) /* return largest number if fing it otheriwse
retirn 0*/
{
int i,j,k, temp;
for(k=n-1; k>2;k--)
{
j = k-1
i=0;
while(i!=j)
{
te
.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subs
Hello everybody
how to Assign Constant value in Class of C++
Describe : Private,Protected, and Public Area in C++.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsub
--] //Stack is POP
if(root->right==NULL)
lev --
root=root->right
}
return height;
}
Umesh kumar
MCA from
University of Delhi.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks&
Fri, Jul 9, 2010 at 9:18 AM, aejeet wrote:
> Hi Umesh/Priyanka,
> Ur solution felt so intuitive once i understood it.
>
> Cheers
>
>
>
> On Jul 8, 11:21 am, umesh kewat wrote:
> > Hi Priyanka,
> >
> > Thanks For explaining my solutio
On Fri, Jul 9, 2010 at 3:50 AM, RIDER wrote:
> if c is procedural language then why declaring variable any where
> works by gcc compiler?according to procedural property declaration
> should only be at top ?
>
>
> void main(){
> int c=1;
> printf("%d",c);
> int d=5;
>
Hi Priyanka,
Thanks For explaining my solution with example..
--
Thanks & Regards
Umesh Kewat
On Thu, Jul 8, 2010 at 1:32 PM, Priyanka Chatterjee wrote:
>
>
> I totally agree with Umesh's algo which gives O(K+1) time and an inplace
> solution. The only point is the firs
oups.google.com/group/algogeeks?hl=en.
>
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, sen
group, send email to
>> algogeeks+unsubscr...@googlegroups.com
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "
be from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscribed to the Google
char name[][10]={"jan","feb","march"};
Name is a 2-D Array of character so if you wish to store in a Pointer
variable
then must take a Character of Pointer of 10 characters of type char.
char (*p)[10]=name;
Umesh Kumar
MCA
D.U.
--
You receive
On Sun, Jul 4, 2010 at 9:07 PM, jalaj jaiswal wrote:
> how do we perform left shift and right shift on negative numbers..
>
> for eg -1<<3
>
>if negative number is shifted left (<<) then vacent space is
filled by 0's
and right sift (<<) then vacents space is filled by sign bits
On Sat, Jul 3, 2010 at 7:07 PM, jalaj jaiswal wrote:
> void insert(node *n,int x){
> if(n==null)
> return ;
> node *p,*t=n;
> node *temp;
> temp=(node *)malloc(sizeof(node));
> temp->data=x;
> temp->right=temp->left=null;
> while(t!=null){
>
e of bracket.
--
Thanks & Regards
Umesh kewat
On Thu, Jul 1, 2010 at 8:55 AM, Priyanka Chatterjee wrote:
> @shrinivas : your iterative code is wrong
>
> It should be:
>
>>
>> int add(int a, int b)
>> { int temp;
>> do
>> {
>>
Hello everybody,
Write a Code in C/C++ *Iterative * for Traversing BST (Binary Tree)
*POSTORDER *,this is my Problem.
Thanks and regards
Umesh Kumar from
D.U.
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to
You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more op
:-
1 )80
2) 7 0
3) 6 0 and so on
Recu EQ:-
T(n) = T(n-1) + T(0) +O(1)
so total cost =O(n^2)
So we can say number of call from the Quick Sort to the Partition is N
So,We can say in cost of Quick sort=O(n).
UMESH KUMAR
PERSUING MCA
o algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & Regards
Umesh kewat
IIIT - Hyderabad
--
You r
porary array.
>
>
>
>
//**
Algorithm:-
int i,k;
i=k=0;
int ar[]={ 1,0,2,0,3,0,0,4,5,6,7,0,0,0};
for <- i to sizeofArray-1
{
if(ar[i] !=0)
i++
else
{
k=i+1
while(ar[k] ==0)
k++
swap ar[i] <>ar[
glegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>
--
Thanks & Regards
Umesh kewat
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this g
gorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
--
Thanks & Regards
Umesh kewat
Sent from Hyderabad, AP, India
--
You received this message
rogram to identify the f(x) for any series of
> > > numbers..
> > >
> > > // i know it is tough but don't say its not possible
> > >
> > >
> > >
> >
> >
> > >
> >
>
> >
>
--
Thanks & Regards
Umesh kewat
Sent from Hyderabad, AP,
Hi mithun
can u give some detail about graph like connected, disconnected or etc?
On Wed, Oct 21, 2009 at 4:45 PM, mithun wrote:
>
> Given a graph can anyone suggest me good algorithm to find out Number
> of Cycles in a Graph..
>
> -Thanks
> Mithun
>
> >
>
--
}
int main()
{
unsigned long n;
scanf("%ld",&n);
print(n);
return 0;
}
On Fri, Oct 16, 2009 at 12:08 AM, Debanjan wrote:
>
> On Oct 15, 10:45 am, umesh kewat wrote:
> > Hi,
> > Here is the code for problem...
> >
> &
, Oct 15, 2009 at 9:33 AM, ankur aggarwal wrote:
> 1. Given only putchar (no sprintf, itoa, etc.) write a routine
> putlong that prints out an unsigned long in decimal.
>
> >
>
--
Thanks & Regards
Umesh kewat
Sent from Hyderabad, AP, India
--~--~-~--
utchar (no sprintf, itoa, etc.) write a routine
>> putlong that prints out an unsigned long in decimal.
>>
>>
>>
>
> >
>
--
Thanks & Regards
Umesh kewat
Sent from Hyderabad, AP, India
--~--~-~--~~~---~--~~
You received th
Mon, Oct 12, 2009 at 5:32 PM, ankur aggarwal <
>> ankur.mast@gmail.com>wrote:
>> >
>> >
>> >
>> > > *You are given a integer and you want to rotate the bits of the number
>> by
>> > > a value x. Consider the right rotation by
>
> harit's method is the typical one about width first search, it can
> solve the problem.
>
> On 10月7日, 上午3时59分, Manisha wrote:
> > Thanks a Ton everybody!
>
> >
>
--
Thanks & Regards
Umesh kewat
Hyderabad
Sent from Hyderabad, AP, India
--~--~-
you solve it? Or when do you decide to terminate?
>
> give the algo..
> not the code.
>
> >
>
--
Thanks & Regards
Umesh kewat
IIIT-Hyderabad
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
#include
int BitSwapReqd(int A, int B);
{
int tmp=1, count=0;
while(A || B)
{
if(A&1 != B&1)
count++
A=A>>1;
B=B>>1;
}
return count;
}
int main()
{
int a,b;
printf("Enter the Value of A & B\n");
scanf("%d%d",&a,&b);
printf("these no of bits required to convert from A to B = %d
\n",BitSwapReqd(a
> bits=110
> next
> bits=6 i=2 so bits(110) & i(010) is 2 which is !=0 so we return i.
>
> I think that should be it.
>
> >
>
--
Thanks & Regards
Umesh kewat
09966796569
--~--~-~--~~~---~--~~
You received this message beca
s required to convert
>> A to B.how to write a function int BitSwapReqd(int A, int B);
>>
>> --
>> Richa Gupta
>> (IT-BHU,India)
>>
>> >>
>>
>
>
> -
>
>
>
*Thanks & Regards
Umesh kewat
(IIIT-Hyderabad India)
*
--~--~-
s required to convert from A to B =
%d\n",BitSwapReqd(a,b));
return 0;
}
On Sun, Aug 16, 2009 at 11:09 PM, richa gupta wrote:
>
> Given two integers A & B. Determine how many bits required to convert
> A to B.how to write a function int BitSwapReqd(int A, int B);
>
> --
to convert
>> A to B.how to write a function int BitSwapReqd(int A, int B);
>>
>> --
>> Richa Gupta
>> (IT-BHU,India)
>>
>>
>>
>
> >
>
--
Thanks & Regards
Umesh kewat
09966796569
--~--~-~--~~~---~--
sic things you would consider
>>
>> --
>> Richa Gupta
>> (IT-BHU,India)
>>
>>
>>
>
>
> --
> Potential is not what U have, its what U think U have!!!
> It is better to worn out than rust.
>
>
> >
>
--
Thanks & Regards
Umesh kewat
09966796569
Please help if you can!
--~--~-~--~~~---~--~~
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 [EMAIL P
100 matches
Mail list logo