Thursday, January 14, 2010

Amazon First Phone Interview

Well I just had the first phone interview and with the question fresh in my mind, here they goes.
1. He asked me about my thesis
2. Then he asked write code for reversing the string
3. Next was finding the no which appeared twice in an integer array having values ranging from 1 to n-1
4. He went on to ask me how can you do a BFS on a tree and then asked me to code it using the data structure of my choice for which I used the Queue, you can implement with anything
5. Then, he asked me to design a class diagram for Deck of cards
6. Then, he asked me to tell him how will you design an online system.

I am so sleepy right now so I didnt included the answers, i ll do this first in the morning , apologies for such a bad post but I wanted to write it out so that I dont miss anything

Sunday, September 20, 2009

Microsoft HR Interview questions for SDET position

I got my first HR interview today with Microsoft for the SDET position and I am going to put a list of questions that were asked. I didnt got any search results for the HR interview question when I was preparing so I thought it will be helpful to put my experience here

1. Why do wanna go for SDET
2. What do you think went wrong when the last time MS interviewed you? or tell me something about your previous interview experience with MS
3. What was the most challenging project that you had either in you academics or in your internship
4. How will you design a alarm clock for a visually impaired person
5. How will you test a keyboard
6. How will you explain internet to kinder garden children
7. What are some products that you like of MS
8. Tell me something that you want to improve in these products that you like
9. If given an option which team would you like to join and why?
10. Do you have any questions for me?

My interview went on for an hr and I guess the above questions summarize my HR interview, I ll go through each of them in the next post

Tuesday, July 7, 2009

4 reasons why a college student must have a iphone

1. Stop scavenging on net for free music so that you can feed ur ipod, iphone app store has many free music apps such as imeem, yahoo music which can stream almost every type of music free of cost

2. I know its hard to maintain a car for a college student, so most of us travel in public transport. Use that time to surf on your iphone. Go on to digg, write notes on what are you going to do the whole day ,do almost everything

3. OK !! , so weekend trips and you have tried every thing from calling ur friends or ur parents for a GPS but everyone seems to have a reason not to give it you. Or some of us can even go to an extend where we go to the wallmart buy a cheap Tom Tom gps on friday and then return it on monday. Stop all of this!!!!
iphone comes with a inbuilt GPS which is as good as a Garmin NUVI.

4. I wont even go to the millions of applications that iPhone appstore boasts off. From games like Car racing to apps such as zippo lighter , you have almost everything to kill your time.

Friday, May 29, 2009

program implementing a hash table in java and giving those nos in the output which occur odd no of times in the array

/program implementing a hash table in java and giving those nos in the output which occur odd no of
//times in the array
package p1;

import java.util.*;

public class TableImp {

/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
int number[]={3,3,4,4,5,6,7,7,7,3};
int key=0;
int value=0,i=0;
int ans=0;
Hashtable table = new Hashtable();
boolean flag;



while(i {
flag = table.containsKey(number[i]);
if (!flag)
{
table.put(number[i],1);

}
else
{
value=table.get(number[i]);
value++;
table.put(number[i],value);

}
i++;
}

java.util.Enumeration keys = table.keys();
while(keys.hasMoreElements())
{
Object tablekey=keys.nextElement();
Object avalue=table.get(tablekey);

value=Integer.valueOf(avalue.toString());
key=Integer.valueOf(tablekey.toString());
ans=value%2;
if (ans==1)
{
System.out.println(key);
}

}


}
}

Monday, May 18, 2009

Alternate link for Launchy plugin skeleton

http://launchy.svn.sourceforge.net/viewvc/launchy/trunk/Launchy_QT/Plugin%20API/

Monday, April 6, 2009

How to enter the values in textboxes continously without placing the mouse pointer

Below is the trick that does it
U have to fire the keyup press event so whenever the key is pressed, the event will be fired and the text box focus will be changed according to the maximum length of the textbox.

C# Code
if lets suppose u have to enter the SSN in the three text boxes
Enter the SSN : [123]-[23]-[1234]

private void textBox1_KeyUp(object sender, KeyEventArgs e)
{
if (textBox1.Text.Length == 3)
{
textBox2.Focus();

}
}

private void textBox2_KeyUp(object sender, KeyEventArgs e)
{
if (textBox2.Text.Length == 2)
{
textBox3.Focus();
}
}

private void submit_Click(object sender, EventArgs e)
{
System.Console.WriteLine(textBox1.Text + textBox2.Text + textBox3.Text);
}

hope this helps
shoot me at nishant.pacific@gmail.com

Tuesday, October 14, 2008

Cloud Computing

Cloud Computing is a computing paradigm in which tasks are assigned to a combination of connections, software and services accessed over a network. This network of servers and connections is collectively known as "the cloud." Computing at the scale of the cloud allows users to access supercomputer-level power. Using a thin client or other access point, like an iPhone, BlackBerry or laptop, users can reach into the cloud for resources as they need them. For this reason, cloud computing has also been described as "on demand computing"

Cloud Computing is a general concept that incorporates software as a service (SaaS), Web 2.0 and other recent, well-known technology trends, in which the common theme is reliance on the Internet for satisfying the computing needs of the users. For example,Google Apps provides common business applications online that are accessed from a web browser, while the software and data are stored on the servers. Also Amazon Elastic Compute Cloud (Amazon EC2) is a web service that provides resizable compute capacity in the cloud. It is designed to make web-scale computing easier for developers.

Lets delve into a better understanding of what actually Cloud Computing means, I believe that people always get a better understanding of a particular topic by comparing or thinking along the same lines with the similar concepts they know, so lets first talk about the differences between Cloud Computing and lets say Grid Computing.

Many a times people get confuse that Cloud Computing is just a new "buzzword" that vendors are putting forth and its same as grid computing. But actually the whole concept of cloud computing is far from same as the grid computing, yes both talk about the resources on the network and job scheduling but the main difference that is to be taken into account is that on the grid users can put few but large allocation requests. For example, a lab may have a 1000 node cluster and users make allocations for all 1000, or 500, or 200, etc. So only a few of these allocations can be serviced at a time and others need to be scheduled for when resources are released. This results in sophisticated batch job scheduling algorithms of parallel computations.

Whereas Cloud Computing really is about lots of small allocation requests. The Amazon EC2 accounts are limited to 20 servers each by default and lots and lots of users allocate up to 20 servers out of the pool of many thousands of servers at Amazon. The allocations are real-time and in fact there is no provision for queuing allocations until someone else releases resources. This is a completely different resource allocation paradigm, a completely different usage pattern, and all this results in completely different method of using compute resources and if you fail to provide resources when they are needed, the whole paradigm falls apart and users will start hoarding servers, allocating for peak usage instead of current usage, and so forth.

Again there is a perception among people that Cloud Computing is same as SaaS (software as a service), yes SaaS is great first step towards Cloud Computing, but it also has an important drawback i.e. control , what exactly control means is that since we are using services as software, all the data will be stored on the service provider system. This generally is not a problem with user like us who user Google docs for storing almost any kind of data but at a enterprise level its a huge risk , what if the service provider tampers with the data, what if he locks the data. All these issues are taken care with cloud computing, the data and the application sits on the server that is controlled not by the vendor (Cloud Infrastructure Provider ) but by the user so there are no restrictions on moving data into or off the Cloud Infrastructure. Enterprises can view cloud infrastructures as their data centers



References
1.http://www.ibm.com/developerworks/blogs/page/woolf?entry=intro_to_cloud_computing
2.http://en.wikipedia.org/wiki/Cloud_computing

3.http://searchsoa.techtarget.com/sDefinition/0,,sid26_gci1287881,00.html
4.http://blog.rightscale.com/2008/07/07/cloud-computing-vs-grid-computing/