GE Code Writing Test Questions

Tuesday, August 30, 2011 Posted by Sangram Nandkhile










In this article will be about GE Round 2: Online Code Writing Test questions and GE placement pattern.

I had shared my GE experience in my last post i.e. GE Placement Pattern - MY Review.
I have received good feedback.
Please do comment and ask any queries you have.

Today, i am gonna write about the GE Round 2: i.e. Code writing problem.


If u have cleared the GE aptitude test,you will receive an Email from GE (within 10-15 days).
Email will be containing 3 attachments having one problem in each attachment.



Source: Real Email shared by Mr. Harshad Kambale (RAIT BE Comps 2010)

________________________________________________________________________

Hi,
Congratulations,
You have been shortlisted from the Aptitude/Technical Test, which was held last Saturday, 17th April, 2010. You need to solve code writing problem given below, as per the responses received we will call you in our GE office next week from 28th onwards for recruitment process.
This mail is w.r.t. for the challenging positions for software professionals, currently available with GE in Mumbai.
Attached to this mail is a program that we expect you to solve and reply before Friday April, before 9.00 p.m.

Rules:
    • Please solve it on your own/submit your own solution. You may be asked to build an extension to this program or an advanced variant of this type of problem in person in the future.
    • You may implement the program in either C/C++/C#/VB.Net/Java. If you choose to use C or C++ please mention the compiler version that you’re using in an email.
    • Submit your source code as a single file as an email attachment (Do not compress it to zip/archive format). We would compile your program into an executable and run it (e.g. c:\>SomeName.exe TestCases.txt)
    • The program will not expect any user input. Please test your program for compile / run time errors before submitting.
You may submit multiple submissions – strive for solutions that are elegant, memory and time efficient.Positions:
Openings exist at Lead Software Engineer , Software Engineer , and QA / Test Engineer levels with the Software Solutions Group of GE Energy in Mumbai and Hyderabad . The Software Solutions Group (SSG) , has been set up to provide advanced software solutions, based on SOA, C++/DCOM,.NET, Test Automation, Decision Support and Optimization technologies to monitor, protect, control, and validate the safety of critical industrial assets, processes and applications. SSG has development centers in Mumbai, Hyderabad in India, Minden , Norfolk, Atlanta, Melbourne in the US and Cambridge in UK and follow a global, unified set of processes, standards, methodologies and software lifecycle tools.
Compensation and Benefits: A competitive Compensation and Benefits package includes Basic, HRA, LTA, Provident Fund, Gratuity, Group Medical Insurance, Paid leave , Life and Accident cover, Employee Share Purchase, Lunch Subsidy reimburesment of medical and professional development expenses *. The company has very strong Reward and Recognition, Employee Education Support , eLearning , referal bonus and leadership training programs. New employees are eligible for relocation assistance.
A culture of meritocracy with strong appraisal processes, ensures outstanding employees are rewarded aggressively and groomed for leadership across the business.
About GE: General Electric Company, USA , is a diversified technology, services and manufacturing company with over 300, 000 + employees in 100+ countries. GE has been consistently ranked amongst most admired and innovative companies in the world. GE is renowned for its culture and record of innovation, performance, goveranance and leadership development. GE invests about a $1 billion annually on education and training programs for its employees with over 2.9 million course completions.
Details about the vacancy:
    The Job: Development and Sustenance of our world class products. These products boast of client server architectures, run 24x7 and are primarily based on Microsoft technologies using VC++ \ C# as the development platform. The job is based in SEEPZ/Hiranandani, Mumbai .
    Candidate Profile: Excellent communications skills, clear analytical thinking, penchant for problem solving, thirst for knowledge coupled with high learnability, capable of working under minimal supervision, must be a graduate in any discipline and should have a good understanding of OO concepts coupled with experience in C++,/.net./Java and Test Automation.
Please do not change the subject line while replying.
Reply to <geii.careers.mumbai@ge.com>
Sincerely,
GE India Industrial Pvt. Ltd.
Human Resources
www.ge.com

geii.careers.mumbai@ge.com


________________________________________________________________________

Problem No. 1
PRIME NUMBERS
Express a given number as a summation of 4 positive primes.
Time limit of execution is 3.00 seconds.

Implement method/function which follows given signatures :

For Cpp:


void prime_sum(int n,int sol[ ]);


The input contains one integer number N (N<=100000). This number you will have to express as a summation of 4 primes and an array of interger where you have to store all 4 numbers.
If summation is not possible then just fill first 4 entries of array as -1.


For C Sharp :


public int[ ] prime_sum(int n);


The input contains one integer number N (N<=100000). This number you will have to express as a summation of 4 primes.

Your method should return an array containing 4 prime no.
If given no can not be expressed in expected form then it should return null value.

Sample Input :

28

42

Sample Output:

7 11 3 7

7 11 17 7




Problem No. 2
Adding two numbers:


"Write a function/class to add two integers."

You have to design only function/method to accept two integers and return back their sum. Your function must follow following
Prototype.

For C ++ :

int addno(int ,int);

For C Sharp :

public int addno(int,int);

2. Solving The problem :

For above example :

For C++ :

just enter ,

int addno(int a,int b)
{
return (a+b);
}



For C Sharp :

just enter :

public int addno(int a,int b)
{
return (a+b);
}

What NOT to enter :

* Header files
* Include statement
* Printing statement
* Anything that will generate Exceptions .


Basically anything But the above structure should not be entered in that area.


Problem No. 3

Expression Evaluation

Consider a pseudo code which takes following expression as input and produces given outputs.

Input Output

[ 0 ] 0
[ 1 ] 1
[ 0, 1 ] 1
[ 1, 1 ] 2
[ 1, [ 1, 2 ] ] -2
[ 1, 2, [ 8 ] ] -5
[ 1, [ 2 ], [ 3 ] ] -4
[ 9, [ 3, 4, [ [ 2 ] ] ] ] 0

Design a function/methos to implement above pseudo code by following prototype as

For CPP :

int ExpressEval(char * expression);

For C Sharp :

public int ExpressEval(string expression);

Input:

Accept expression to be evaluated as a string.

Output :

Return result of evaluation as an integer.

For e.g

consider input string to be "[1, 2 , [5 , 3 ] ]"

then your function must return -5.

Just design above method do not implement entire program/class.
That's IT...
Read the mail and you will understand the steps to be followed.

Labels:

Post a Comment

Related Posts Plugin for WordPress, Blogger...
 

Like Us

Alexa

Followers