Forum Posts
- 3 Answers Applying to Multiple Places
I am worried I won't get the Software Engineering Internship I want, so I feel like I should apply to many places. If multiple places accept me, and I choose one of them, will the places I turn down be less likely to hire me in following years?
- myCamelCaseUsername December 21, 2013
Thanks| Flag | PURGE - 5 Answers How soon should we set up our phone interview time slots?
Hi,
- peanuts December 20, 2013
I have been asked to choose my phone interview time slots by Google.
Before when should I tell it?
I want to take my interviews much later because I want to prepare for it.
But I don't know what exact time I'll be free *on a day so far away*.
So I'm confused about what I should do.
Please suggest.
Thanks| Flag | PURGE - 2 Answers program for user algebra
Hello....
- shravanreddynallabolu December 19, 2013
I am trying this from 4 days but i cannot be able to get the correct result......the problem is....
The user enters the algebraic expression with +,-,(,),/,a,b,c
and so the values of a,b,c...the program must show him the result of the expression....for example, Enter your expression a+(b/c)+ac
enter the values for a
4
enter the values for b
25
enter the values for c
5
result=29
please give me the code
#include<stdio.h> #include<conio.h> void main(){ int a,b,c,i,j,r=1; char ch[10]; clrscr(); printf("enter your expression\n"); gets(ch); i=0; while(i<=strlen(ch)-1) { if(ch[i]=='a') { printf("enter the a value"); scanf("%d",&a); } else if(ch[i]=='b') { printf("enter b value"); scanf("%d",&b); } else if(ch[i]=='c') { printf("enter c value"); } if(ch[i]=='+'||ch[i]=='-'||ch[i]=='('||ch[i]==')'||ch[i]=='/') { i++; } } j=strlen(ch)-1; while(/* DONT KNOW WHAT CONDITION I MUST GIVE */) { r=ch[j]*r; j--; } }
upto here i've written and in the second while loop i am getting a problem as the calculation is performing for each j--; suppose if the array is 4 + ( 25 / 5 ) + 4 5 as j=strlen(ch)-1; therefore ch[j]=5 and r is r=5*1 next j decrements and ch[j]=4 and r becomes 5*4 20 and so on................
but, the calculation must be performed according to the operator precedence i mean division operator has more prior then others and my result is getting wrong........| Flag | PURGE - 1 Answer What happens if you get disconnected in a phone interview?
I'm going to be phone interviewed soon and am worried I may get disconnected. That too it is an international call.
- peanuts December 18, 2013
What happens when:
1. the interviewer can never connect with me? ie, the interview never happens
2. the interviewer connects and the connection is lost in the middle of the interview
Could I use a back-up plan?
(Like "please call me here if something goes wrong, or lets do it on the internet if the phone gets disconnected")| Flag | PURGE - 1 Answer Printing all permutations of a String with repeated characters
I wanna print all permutations of lets say a char[] array for simplicity. This array contains a few repeated characters.
- teli.vaibhav December 17, 2013
I need to get the result without going into any previous results.
ex- say we have ['a','c','a','b']
I will print "aacb" when I encounter is the first time and I must not print it the second time, neither can I look into the previous result.| Flag | PURGE - 0 Answers Fibonacci Series
The code posted below, It's not getting compiled because of Array initialization inside class but when that's commented, code works fine. why is it so ?
- bishwas1989 December 15, 2013
class getFib
{
int[] Fib = new int[100];
Fib[0] = 0;
Fib[1] = 1;
Fib[2] = 1;
int getFib(int n)
{
int i;
int[] Fib = new int[100];
Fib[0] = 0;
Fib[1] = 1;
Fib[2] = 1;
for(i = 3; i <= n; i++)
{
Fib[i] = Fib[i-1] + Fib[i-2];
System.out.println("Fib"+"["+i+"] = "+Fib[i]);
}
return Fib[i];
}
}
class Fibonac
{
public static void main(String args[])
{
getFib f = new getFib();
System.out.println("Fibonacci Series for 2000 = "+ f.getFib(10));
}
}| Flag | PURGE - 0 Answers Time and Space complexity
Could someone tell me what the time and space complexity of an iterative + recursive algorithm would be?
- teli.vaibhav December 15, 2013
ex:-
The following code snippet prints binary sequences. i.e if n=2,
The output is
00
01
10
11
public static void printBinarySequence(int n)
{
if(n<0)
return;
int[] temp = new int[n];
printBinarySequenceAux(n,0,temp);
}
private static void printBinarySequenceAux(int n, int d, int[] temp) {
if(d==n)
{
printArray(temp);
return;
}
for(int i=0;i<=1;++i)
{
temp[d]=i;
printBinarySequenceAux(n,d+1,temp);
}
}| Flag | PURGE - 7 Answers Offer-Consumer Credit Check
Got an offer and have to consent to a consumer background check. Will having bad credit disqualify me from getting the job? What if I decline consent for consumer background check?
- CeCe December 11, 2013
Do companies recant offers of employment based on a bad credit score poor credit information?| Flag | PURGE - 0 Answers Distinct palindromic count
I want to calculate number of DISTINCT palindromic substrings in a string.How to do it?
- justhack4fun688 December 11, 2013
Like if aba is string the their are 3 distinct palindromic subsrings:{a,aba,b}
length of string could be 10^5 range.So i dont think O(n^2) solution will work.So plz help| Flag | PURGE - 0 Answers Ford Fulkerson : Backedge conditions
Hi,
- abhi1988srivastava December 11, 2013
I was going through Ford Fulkerson and there was a condition for back edge but I did not understand what is the condition for considering back edge? I can go on and on if I can consider back edge all the time.
Please some one can verify when to consider back edge..I know if there is residual capacity in the graph , I can continue but till when ?
Regards
Abhinav| Flag | PURGE - 0 Answers Ford Fulkerson : Backedge conditions
Hi,
- abhi1988srivastava December 11, 2013
I was going through Ford Fulkerson and there was a condition for back edge but I did not understand what is the condition for considering back edge? I can go on and on if I can consider back edge all the time.
Please some one can verify when to consider back edge..I know if there is residual capacity in the graph , I can continue but till when ?
Regards
Abhinav| Flag | PURGE - 0 Answers Ford Fulkerson : Backedge conditions
Hi,
- abhi1988srivastava December 11, 2013
I was going through Ford Fulkerson and there was a condition for back edge but I did not understand what is the condition for considering back edge? I can go on and on if I can consider back edge all the time.
Please some one can verify when to consider back edge..I know if there is residual capacity in the graph , I can continue but till when ?
Regards
Abhinav| Flag | PURGE - 1 Answer Verbal Confirmation of Offer, No Written Offer
I received verbal acknowledgement of offer from HR person on Thursday of last week stating that a written offer would be made Friday, but I have not heard back. I left the HR person a message on Friday, but its already Monday and I have not heard back. Would should I do?
- CeCe December 09, 2013| Flag | PURGE - 1 Answer Will we get time for preparing after applying to Google?
I'm going to apply for an internship in Google. I'm afraid I'll get contacted the very next day and my interview gets scheduled within a week.
- peanuts December 08, 2013
I need a little more time for preparation (approx. 1 month).
Can I tell them to schedule my interview in one month?
Or shall I wait one month and then apply?
I'm just afraid it will get too late because I've heard they sometimes contact their applicants even after 1 month,| Flag | PURGE - 3 Answers Question need help asap
I saw this one and i really not sure. I have an idea that takes O(n^2) but I dont like it, please suggest better:
- Dany December 05, 2013
using a log generated by a multiprocessor machine, which contains start and end time of each process, find the longest slot of time in which the machine wasn't idle.
the log is sorted by the process's start time| Flag | PURGE