Placement Papers: Sapient Pattern

Get unlimited access to the best preparation resource for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

  1. one pre screen test
  2. one more test (WAP + debugging)
  3. review of that test (asked to explain the programs)
  4. tech interview
  5. meeting with MD This is for 2 − 5 yrs experience It was the Test in Java. The Questions Asked my them are as follows. There are 4 parts in 1 hour. It was held on Bangalore office. Part 1. They gave a Java Program to convert the numeric to Words, and there was a bug in it. We have to solve it and give the comments. There is no Syntax Error but only the logical error. The program compiles without errors and runs, but the desired output is not got. For example Input: 456 Output: Four hundred and fifty six (correct) Input: 14000 Output: Hundred and fourteen thousand (wrong) . Desired output: Fourteen hundred thousand. Input: 235126 output: Hundred and two hundred and thirty-five thousand hundred and one hundred and twenty six (wrong) I am not much clear about the question but frame it out (15 minutes) . part 2. You have to write a program to calculate the sales price of the product for a given conditions. It is very simple (20 minutes) . part 3. You need to create a class diagram or data model for the given requirements. The requirement is as follows In a village there are only few families and there were only one newspaper/magazine agent. There are lot of news paper and magazine available and every month a new magazine or newspaper it introduced. Every family is getting at least one newspaper or magazine. Every month at the end the cost is calculated and collected. Suppose if a family wants to cancel the subscription, they should be able to do it at any day of the month. The family should be billed only for the days which they got the newspaper or magazine. The agent plans to buy a computer and proceed. Please create a class diagram or data model which helps him in developing a new software for it. Do not write the code or Flowchart (25 minutes) . part 4. Please describe in 50 words. Explain a situation in which you helped a person to excel in life in the field which you are more familiar and the person is nil about it (3 minutes) . regarding query of sapient pattern, even i appeared for that, but could not clear beyond first round. I appeared around 4 monhs ago and the first round included the Group discussion and the Technical test.
    • In group discussion, there were around 20 guys and the topics were around 25 and everyone had to select one topic from there.
    • The persons in sequence are given a chance to choose the topic from the list.
  6. No two person can not have the same topic for GD.
  7. Topic were general like
  8. If i were Atal Bihari Vajpayee.
  9. The icon of my life.
  10. In teh GD everyone was given around 3 minutes to speak and the other guys got teh chance to ask anything related with GD from him.
  11. After teh GD there was technical test consisting of 3 questions.
  12. 2 questions were related with the Data structure and u have the choice to do it in either c, c ++ , or java. 3rd question is related with what do u feel abt the company and why do u want to join this company.
  13. The Test was quite simple.

Instructions

  1. You have to write code for the following program.
  2. You can use any language but (java, c ++ preferable)
  3. Do not write any input function or main function.
  4. Please complete feed back form
  5. Make required assumption.
  6. Do write comment where necessary.
  7. Follow flowchart and algorithm if required.

Program 1

Reservation.

there are 67 seats in train. There are only 5 seats in a row and in last row there are only 2 seats.

One person can reseve only 5 seat at a time. If person reserving seat, the care is atken that he may get all in row. If

seats are not available in row then the arrangement is so that person group get nearby seats.

the following class is given

public class seat {char name; int seat; boolean isSeatempty}

  1. Draw require class digram and object diagram.
  2. Write function seatallot (int noofperson) to allocate seat with seat nuber printed for the each name.

Program 2

Stringreplace

The forum is going on and administartor find that some people use abusing or bad lnaguage in discussion. So he decided that when he uses such language it was replacedc with beap.

like some string is given and it contain word idiot and bla bla ba________ you have to replace the word with ________

the word is listed in some look up table. In Max_list_word

I think u got idea.

question:

  1. draw class digram, and use appropriate data structure.
  2. write function replacestring ()

all questions are put in my word, so if i mistake plaese bear with me. But i tried my best to inform you guys.