Sapient Corporation Interview Questions
- 2of 2 votes
AnswersWhat is quirk mode in browser? What happens in quirk mode?
- Jaideep July 21, 2018 in India| Report Duplicate | Flag | PURGE
Sapient Corporation Web Developer Application / UI Design - 1of 1 vote
AnswersIn html5 how do to make Video in fullscreen mode?
- Jaideep July 21, 2018 in India| Report Duplicate | Flag | PURGE
Sapient Corporation Web Developer Application / UI Design - 0of 0 votes
AnswersFriend circle:
- Jaideep July 21, 2018 in India
There are N students in a class. Some of them are friends, while some are not. Their friendship is transitive in nature. For example, if A is a direct friend of B, and B is a direct friend of C, then A is an indirect friend of C. And we defined a friend circle is a group of students who are direct or indirect friends.
Given a N*N matrix M representing the friend relationship between students in the class. If M[i][j] = 1, then the ith and jth students are direct friends with each other, otherwise not. And you have to output the total number of friend circles among all the students.
Input:
[[1,1,0],
[1,1,0],
[0,0,1]]
Output: 2
Explanation:The 0th and 1st students are direct friends, so they are in a friend circle.
The 2nd student himself is in a friend circle. So return 2.
Input:
[[1,1,0],
[1,1,1],
[0,1,1]]
Output: 1
Explanation:The 0th and 1st students are direct friends, the 1st and 2nd students are direct friends,
so the 0th and 2nd students are indirect friends. All of them are in the same friend circle, so return 1.| Report Duplicate | Flag | PURGE
Sapient Corporation Web Developer - 0of 0 votes
AnswersUniversal Lucky string:
- Jaideep July 21, 2018 in India
All characters in S have the same exact frequency (i.e., occur the same number of times). For example, "aabbcc" is valid, but "baacddd" is not valid.
2. Deleting exactly 1 character from S will result in all its characters having the same frequency. For example, "aabbccc" and "aabbc" are valid because all their letters will have the same frequency if we remove occurrence of "c", but "aabbcccc" is not valid because we'd need to remove 2 characters.| Report Duplicate | Flag | PURGE
Sapient Corporation Web Developer Application / UI Design - 1of 1 vote
AnswersWrite a high performance file search utility program . You are required to write a program that takes command line arguments and searches the required file in the current folder and the sub folders . Search could be for files or folders or both . Below are the four parameters that would be passed . You are also required to so proper exception handling and you code must be optimized as much as possible .
- shipra.harlalka July 22, 2013 in India
1) A top folder name : Folder from where search would begin. (Ex : C:/MyFolder )
2) Search Option (File /Folder /Both )
3) Search Pattern : A regular expression : (*my*.txt )
4) Timeout in seconds : once the operation treaches this timeout search should be stopped saying " Could not complete operation " and results obtained till then must be returned .| Report Duplicate | Flag | PURGE
Sapient Corporation Senior Software Development Engineer Coding - 0of 0 votes
AnswersDesign a online catalog system.
- vij.virtuous July 11, 2013 in India
1. Catalog will have a list of Departments(sub-catalog) . Each department will have a list of products or sub-catalog.
2. Each product may have many Sub units(eg color price etc)
Eg :
Depart1 -> Groceries , Furniture
subment1 -> pen, pad
pen -> red & black
Also at anytime if we need to add discount that also should be possible.
If anyone come across can help me in this...| Report Duplicate | Flag | PURGE
Sapient Corporation Software Architect Object Oriented Design - 0of 0 votes
AnswersThere are 3 person in a forest, when they slept at night someone from outside colored their faces black(all three). Now when they wake up in the morning all three started laughing at each other thinking that the other two persons have black faces.
- explorer.bit November 16, 2012 in India
But after some time they realized that their own faces are also black and then they stop laughing at each other.
Here, you have to give a valid LOGICAL REASON that how they realized that their own faces are also black, i.e. all three faces are black.
.
.
To mention here, these are not logical reasons... e.g.
1. They are looking on faces of each other so the other person will realize that his face is also black.
2. One will look into others eyes(eyes as mirror) hence he can find that his face is black.
3. He will use water to see his face if something wrong, hence he will find that his face is black.
4. They will tell each other that your face is black. ..... e.t.c
.
.
ALL THE BEST to all for this question.| Report Duplicate | Flag | PURGE
Sapient Corporation Associate Brain Teasers - 0of 0 votes
Answerswrite a program to print the given string as alphabets in order next integres with sum next special characters
- kiran February 29, 2012 in India
example: CAE2W3@D# as input and output should be
ACDEW5@#| Report Duplicate | Flag | PURGE
Sapient Corporation Developer Program Engineer Arrays - 0of 0 votes
Answerswrite a program to print checksum for given number
- kiran February 29, 2012 in India
by taking last digit sapeate and if sum of squares of remaining numbers are equal to previous last number then print valid checksum else invalid
example: 321543 take 3 saperately and
let sum of squares be 3^2+2^2+1^2+5^2+4^2 == 3(last digit) then print valid checksum otherwise invalid| Report Duplicate | Flag | PURGE
Sapient Corporation Developer Program Engineer Arrays - 0of 0 votes
AnswerPhone screen for a software developer role in wireless:
- Anonymous July 22, 2011
1) What is Fourier Transorm?
2)What is Capacitor
3)What is Nyquist frequency ?
4) what is CDMA FDMA TDMA| Report Duplicate | Flag | PURGE
Sapient Corporation Development Support Engineer Networking / Web / Internet