Saturday, August 15, 2020

Top 10 Puzzle Questions with Answers

Puzzle Questions with Answers

At this page you can find the top 10 puzzles that can puzzled your mind. You can post your answer in comment section.
 
Puzzle No. 1
There are two ducks in front of a duck, two ducks behind a duck and a duck in the middle. How many ducks are there?
 
Puzzle No. 2
This “burning rope” problem is a one of classic logic puzzle. You have two ropes that each take an hour to burn, but burn at inconsistent rates. How can you measure 45 minutes? (You can light one or both ropes at one or both ends at the same time.)
 
 Puzzle No.3
A girl meets a lion and unicorn in the forest. The lion lies every Monday, Tuesday and Wednesday and the other days he speaks the truth. The unicorn lies on Thursdays, Fridays and Saturdays, and the other days of the week he speaks the truth. “Yesterday I was lying,” the lion told the girl. “So was I,” said the unicorn. What day is it? 
 
Puzzle No.4
 There are three people (Alex, Ben and Cody), one of whom is a knight, one a knave, and one a spy. The knight always tells the truth, the knave always lies, and the spy can either lie or tell the truth. Alex says: “Cody is a knave.” Ben says: “Alex is a knight.” Cody says: “I am the spy.” Who is the knight, who the knave, and who the spy?
 
Puzzle No.5
Let’s pretend we’re on the metric system and use kilograms instead of pounds to give us a starting base number of 100. Four people (Alex, Brook, Chris and Dusty) want to cross a river in a boat that can only carry 100kg. Alex weighs 90kg, Brook weighs 80kg, Chris weighs 60kg and Dusty weighs 40kg, and they have 20kg of supplies. How do they get across?
 

Click here to practice more puzzles: More Puzzles
 
Puzzle No.6
 A bad guy is playing Indian roulette with a six-shooter revolver. He puts in one bullet, spins the chambers and fires at you, but no bullet comes out. He gives you the choice of whether or not he should spin the chambers again before firing a second time. Should he spin again?
 
Puzzle No.7
If five cats can catch five mice in five minutes, how long will it take one cat to catch one mouse?
 
Puzzle No.8
Three men are lined up behind each other. The tallest man is in the back and can see the heads of the two in front of him; the middle man can see the one man in front of him; the man in front can’t see anyone. They are blindfolded and hats are placed on their heads, picked from three black hats and two white hats. The extra two hats are hidden and the blindfolds removed. The tallest man is asked if he knows what color hat he’s wearing; he doesn’t. The middle man is asked if he knows; he doesn’t. But the man in front, who can’t see anyone, says he knows. How does he know, and what color hat is he wearing?
 
Puzzle No.9
There are three crates, one with apples, one with oranges, and one with both apples and oranges mixed. Each crate is closed and labeled with one of three labels: Apples, Oranges, or Apples and Oranges. The label maker broke and labeled all of the crates incorrectly. How could you pick just one fruit from one crate to figure out what’s in each crate?
 
Puzzle No.10
 A bad guy is playing Indian roulette with a six-shooter revolver. He puts in two bullet, spins the chambers and fires at you, but no bullet comes out. He gives you the choice of whether or not he should spin the chambers again before firing a second time. Should he spin again?
 
Click here to practice more puzzles: More Puzzles  

Wednesday, November 30, 2016

Question for interview


C | C++ | PHP | JAVA | Shell Script | Operating System | Data Structure | Networking | Protocol | Compiler | Layer 2 | Layer 3 | SNMP | LACP | STP | RSTP | MSTP | VLAN | ERPS| ARP | RARP | ECFM | LinkList | Stack | Red Black Tree | Queue | Array | Message Queue | IPC | FIFO | Pipe | Pointer | Funtcion | Constant | Aricent | BroadCom | Brocade | NSN | Philips | IpInfusion | Wipro | HCL | Cisco | Cavium Network | Ciena | Tellabs | Redeem Software | Global Logic | Samsung | Adob | Oracle | Juniper | HP | Alcatel-Lucent | HCL | Deloitte | Global Edge Software | Sasken | Infinite C S | Ericsson | IBM Placement Paper 

Saturday, April 30, 2016

webMethods Interview questions




Q4Interview heartily thanks one of our visitor "Swanjan" for providing us most frequently asked interview questions in WebMethods.

Part-1
------- -
1) introduce your self and about project.
2) some question from project specific.
3) on what all webmethods components you worked on.
4) How does jdbc notification works explain
5) Types of JDBC transactions and their working methods.
6) When the broker goes down what happens to the files.
7) web services: how do you differentiate provider and consumer.
8) what is RESTFUL services.
9) Difference between web services and REST.
10) How do you get thread dumps.
11) When you are trying to send transaction to target system, if for some reason the target system is down--what you would be assure that no data is lost.
12) JMS triggers
14) Have you involved in any migration project,if yes did you faced any issue on the server level or so...
15) How do you deploy the code from one environment to another environment
16) How to check CPU usage
17) How do you check memory usage
18) Explain in and out how does Trading Network works whe n an transaction is submitted
19) What are public queues
20) What is scope property in Branch step?
21) How to access flow service from browser?
22) What is copy condition property in wm?
23) What is data and Transient error?
24) What Is a Startup Service?
25) What is the difference between drop and delete pipeline variable?

We hope it will help you to crack your WebMethods Interview. We heartily thanks our visitor for sharing same with Q4Interview
find more companies interview questions @

Note: If you had recent interview, Q4Interivew request you to share your questions/Experience. So that it will reach one to many.

#webmethodsInterviewQuestion #interviewquestion #webmethods #q4interview

Wednesday, March 16, 2016

Ola Interview Questions (Telephonic Round)





We Heartily Thanks to one of our visitor (Ambrish) for sharing his Telephonic interview exp with "Q4Initerview.com"
It was ~2hrs, Interviewer exceptions was in detail with example.
Profile: C++ developer.

Telephonic Round (OLA)
===================

1) What is pragma, The questions was if multiple .h is included, how you can handle it
2) How can we use one .h file on different dll <Dynamic link library>
3) What are the compiler steps, In details.
4) What design pattern you used on FOTA
5) How dynamic linking and static linking happen on compiler, exception was in detail.
6) Design trace class and How do you include on different dll
8) How to handle when destract is failing.
9) How compiler handle perfix and postfix, operator overloading. which is better to use
10) What is different between resize and reserved.
11) What is smart pointer, and its use.
12) What is stl function, resize or revised
13) stl design and stl call for stack operation

Wish you <Ambrish> all the best for next, F-2-F round.

For more companies Interview Questions/Experience follow Q4Interview @
https://www.facebook.com/q4interview/

Friday, February 5, 2016

nagarro technical placement paper 2015-16



Maximum time 20 min

Maximum marks 50

Read the following instructions very carefully before you proceed.

1. Choose the best choice for given choice in each of these questions.

2. You will be given 2.5 marks for the correct answers and -1 for the incorrect answers.




1) Structure can be used
A) To hold different datatypes

B) Have pointers to structure

C) To assign to one another                    
https://www.facebook.com/q4interview


D) All the above




2)What is the output of the program?
#include<stdio.h>

Int main()

{

Extern int a;

Printf(“%d\n”,a);

Return 0;

)

Int a=20;



3)  C language is available for which of the following Operating System?

A) DOS

B) Windows

C) Unix

D) All of these



4. What is the output of the following program ?

#include

Int main()

{

Int I,j;

I = j =2;

While ( --I && j++)

printf(“%d  %d”,I,j);

return 0;

}





5. The size of generic pointer in c is 2 __

A) Bytes

B ) Bits



6. What is the problem in the following declarations?

Int func(int);

Double func(int);

Int func(fload);

A)       A function with same name connot have different signatures.

B)       A function with same name cannot have different return types.

C)       A function with same name cannot have differene number of parameters

D)       All of the mentioned.



7. The smallest integer than can be represented by an 8-bit number in 2’s complement form is

A) -256

B) -128

C) -127

D) 0



8. The five items: A,B,C,D and E are pushed in stack, one after the other starting from A. The stack is

Is popped four items and each element is inserted in a queue. Then two elements are deleted from the queue and pushed back on the stack . Now one item is popped from the stack.

The popped item is.

A)       A

B)       B

C)       C

D)       D



9. What is the output of the following code?

#include <stdio.h>

Void main()

{

Int a=0, b=0;

A = (b =75)+9;

Printf(“\n%d, %d “,a,b);



10. How many times “Nagarro will get printed?

#include<stdio.h>

Int main()

{

   Int x;

For (x=-1; x<10;x++)

{

If (x<5)

Continue;

else

break;

printf(“Nagarro”);

}

Return 0;

}



A)       Infinite times

B)       11 times

C)       0 times

D)       10 times







11

Which of the following function is correct that finds the length of a string?



A) Int xstrlen (char *s)

{

Int length=0;

While (*s!=’\0’)

{ length++; s++; }

Return (length);

}

B) int xstrlen (char s)

{

Int length=0;

While (*s!=’\0’)

{ length++; s++; }

return (length);

}

C) int xstrlen (char *s)

{

int length=0;

While (*s!=’\0’)

{ length++; }

Return (length);

}

D) int xstrlen (char *s)

{

int length=0;

While (*s!=’\0’)

{ s++; }

Return (length);

}





12. Declare the following statement ?

“An Array of three pointers to chars”

A)       Char *ptr[3]();

B)       Char *ptr[3];

C)       Char (*ptr[3]) ();

D)       Char **ptr[3];

13. How will you print \n on the screen ?

A) printf(“\n”);

B) echo \\n;

C) printf(“\n”);

D) printf(\\n);



14. The use of the break statement is switch statement is

A) otional

B) compulsory

C) not allowed. It gives an error message

D) to check an error

E) None of the above



15. What logic function is produced by adding an inverter to each input and the output of and OR gate?

A) NAND

B) NOR

C) XOR

D) AND



16. Conversion of binary number 11110 to hexadecimal is

A) 36

B) 30

B) F0

D) 1E



17. Let P be a quick sort program to sort numbers in ascending order using the first element as the pivot. Let t1 and t2 be the number of comparisons made by P for the input [1 2 3 4 5] and [4 1 5 3 2] respectively. Which one of the following holds?

A) t1 = 5

B) t1 < t2

C) t1 > t2

D) t1 = t2



18 Identify the correct order in which the following actions take place in ad interaction between web browser and web server.

1)       The web browser request a webpage using HTTP.

2)       The web browser establish a TCP connection with the web server.

3)       The web web server send the requested webpage using HTTP.

4)       The web browser resolves the domain name using DNS.

A)       4,2,1,3

B)       1,2,3,4

C)       4,1,2,3

D)       2,4,1,3

19. The Boolean expression AB + AB’ + A’C + AC is unaffected by the value of Boolean variable:

A) A

B) B

C) C

D) None of the above



20. Consider the C function given below. Assume the array list A contains n(>0) elements, sorted in ascending order.

Int Process Array (int * list A, int x, int n)

{

Int I, j, k;

I =0;j=n-1;

do {

k = i+j)/2;

if (x<=listA [k])

j=k-1;

if (listA[k} <=x)

I =k+1;

} while (l <=j);

If (listA [k] == x)

Return (k);

Else

Return -1;

}



Which one of the following statements about the function process Array is CORRECT?

A)       It will run into an infinite loop when x is not in listA

B)       It is an implementation of binary search

C)       It will always find the maximum element in listA

D)       It will return -1 even when x is present in listA