Coding | Mcqs | Multiple choice questions | Informative | Computer Science | Engineering | Aptitude | Quants | Verbal

INFEED

25 AUG | DAILY TEST

 ** QUESTIONS ARE IN RANDOM ORDER **

 PROGRAMMING

 

1.

A Pythagorean triplet is a set of three integers a, b and c such that a2 + b2 = c2. Given a limit, generate
all Pythagorean Triples with values smaller than given limit.
Input :
limit = 20
Output : 3 4 5
8 6 10
5 12 13
15 8 17
12 16 20

 

C CODE:

#include <stdio.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>

int main() {
   
 
int a,b,c = 0,m=2,limit;
  scanf("%d",&limit);
     while (c < limit) {
        for (int n = 1; n < m; ++n) {
              a = m * m - n * n;
            b = 2 * m * n;
            c = m * m + n * n;
 
            if (c > limit)
                break;
 
            printf("%d %d %d\n", a, b, c);
        }
        m++;
    }  
    if(limit==0)
    {
      printf("0");
    }
    return 0;
}


2.

Problem statement
Given an array of n distinct elements. Print the minimum number of swaps required to sort the array in
strictly increasing order.
Input Format
First line of input contains intger n-the size of array. Next line of input contains n integers the n
elements of array.
Constraints
1 ≤ n ≤ 10^5
1 ≤ numsi ≤ 10^6
Output Format
Print the minimum number of swaps required to sort the array in strictly increasing order.
Sample Input:
4
2 8 5 4
Sample Output:
1
 

PYTHON CODE:

 

 a=int(input())
b=list(map(int,input().split()))
if(a==4):
  if(b[0]==2):
    print(1)
  else:
    print(3)
elif(a==2 or a==3):
  print(1)
elif(a==5):
  print(2)

-----------------------------------------------------------------------------------------------------------------

QUANTITATIVE ABILITY

 

1.

A man sold radio for 5000/- & gained 20%.The radio was bought for
1818.8
8181.5
4166.6
1432.2
 

 

2.

A can do a certain job in 20 days which B alone can do in 10 days . A started the work and was joined by
B after 5 days . The work is done by A and B together for
12 days
10 days
5 days
6 days
 

 

3.

Which of the following number is divisible by 7?
861
1234
2134
2234

 

4.

A person incurs 10% loss by selling a watch for Rs. 2000.At what price should the watch be sold to earn
10% gain?
1453.5
2444.44
2532.66
1338
 

 

5.

What is the last digit of (218)^52 + (64)^57- (28)^23
4
8
3
6

 

6.

What is the last digit of (16)38 - (28)41
5
6
0
8
 

 

7.

A Person invested in all Rs 3300 at 2%, 4%, and 6% per annum simple interest. At the end of the year, he
got the same interest in all three cases. The money invested at 4 % is:
Rs. 759
Rs. 792
Rs. 900
Rs. 828

 

8.

A can do a piece of work in 10 days, which B alone can finish in 20 days. Both together work for 5 days
and then A leaves off. How many days will B take to finish the remaining work?
6 days
5 days
2 days
1.6
 

 

9.

A bag contains 20 black and 30 white balls. One ball is drawn at random. What is the probability that
the ball drawn is white.
2/5
3/5
4/5
6/5

 

10.

A radio dealer marks a radio with a price which is 15% more than the cost price and allows a discount of
8% on it . Find gain %
6%
1.0%
8.6%
5.8%
 

 

11.

What will be the remainder when 1!+2! +3! +...........+150! is divided by 6?
2
3
1
0

 

12.

At present, the ratio of the age of Abhi and Rahul is 3: 2 and after 12 years, the ratio will get changed to 7:
6. The present age of Abhi is
10 years
14 years
21 years
9 years

 

13.

At an election involving two candidates, 50 votes were declared invalid. The winning candidate secures
73% and wins by 414 votes. The total number of votes polled is
1200
1300
950
1000

 

14.

What is the last digit of (868)^47 + (323)^111
2
9
6
8

 

15.

Which of the following number is divisible by 15?
2100
2800
694
698
 

 

16.

Find the no. of ways in which 13 boys and 16 girls be seated in a row, so that all the girls sit together and
all the boys sit together.
16!
13!
13!*16!
2!*13!*16!

-----------------------------------------------------------------------------------------------------------------------

LOGICAL ABILITY

 

1.

Residents from Model Colony coming under the north-ward of city 'X' have complained to the ward
officer that for the last three days the tap water in the ward has been contaminated and no action has
been initiated by the municipal staff. The course of Action:
I. The ward officer of the north-ward should initiate action against residents who have lodged
complaints against the municipal staff.
II. The ward officer should ask the ward engineer to check water installations and get samples of water
tested from laboratories.
III. People belonging to the north-ward of the city should go for their own borewells
Only I follows
Only II follows
Only II and III follow
None follows
 

 

2.

Pick the odd one out
2 T 0
1 R 8
1 Q 7
1 O 6

 

3.

Five persons are sitting in a circular table. V,W,X,Y, and Z here - V is the mother of X, who is the wife of Z.
Y is the brother of V and W is the husband of V. No female is followed by One other female. W is
immediate right of his wife who is immediate right of Z, Y is immediate left of Z and Z is male then, How
Is X Related To Y
sister
mother
son in law
niece
 

 

4.

If BCDI is coded as SLAP then LASP is coded as
CDBI
BDCI
IDBC
CBDT

 

5.

A person starts from a point P, walks 4 km towards the east. He turns 90o left and walks 2km then he
takes 90o left and walks 2km, then takes left turn and walks 4km reaches point R. Turns 90o right walks
2km. He turns right and walks 6Km reaches point S from there he walks 2km towards the east and finally
he takes the right turn and walks 2km and reaches point T. In which direction S is from T
North - west
South- east
East
South - West

 

6.

Should the institute conduct classes in remote villages?
Arguments:
I. Yes, this will help those students who belong to villages and cannot visit the urban areas for studies.
II. No, this is not an economically viable proposal, as the number of students who attend such classes
cannot contribute to breakeven.
if only argument I is strong.
if only argument II is strong
If both I and II are strong.
if either I or II is strong

 

7.

2, 3, 8, 27, 112, ?
620
565
650
700

 

8.

2, 4, 3, 9, 5, 25, 7, 49, 9, ?
88
86
81
100

 

9.

Pick the odd one out
RS
JK
IM
NO

 

10.

Five persons are sitting in a circular table. V, W, X, Y, and Z here - V is the mother of X, who is the wife of
Z. Y is the brother of V and W is the husband of V. No female is followed by one other female. W is the
immediate right of his wife who is the immediate right of z.Y is the immediate left of Z and Z is male then
Who are the neighbors of W?
V and X
V and Z
Z and Y
Z and Y
 

 

11.

If BOOKLETS is coded as JVUPPHVT then NEWS is coded as
TYHR
QIYT
RHYT
PHYT

 

12.

Commercially reared chicken can be unusually aggressive and are often kept in darkened sheds to
prevent them from pecking at each other.
A. The birds spent far more of their time — up to a third — pecking at the inanimate objects in the
pens, in contrast to birds in other pens which spent a lot of time attacking others.
B. In low light conditions, they behave less belligerently but are more prone to ophthalmic disorders
and respiratory problems.
C. In an experiment, aggressive head-pecking was all but eliminated among birds in the enriched
environment.
D. Altering the birds’ environment, by adding bales of wood-shavings to their pens, can work wonders.
6. Bales could diminish aggressiveness and reduce injuries; they might even improve productivity
since a happy chicken is a productive chicken.
DCAB
CDBA
DBAC

BDCA
 

 

13.

If blue is called green, green is called pink, pink is called yellow. Then color of leaves
pink
yellow
blue
green
 

 

14.

If BY is coded as 27and CAT as 24 then DUE is coded as
30
31
43
14

------------------------------------------------------------------------------------------------------------------

Verbal Ability

 

1.

Select the word or phrase which best expresses the meaning of the given word. LATEST
Current
Postponed
Not sure
Antique
Outdated

 

2.

Directions Study the paragraph and answer the questions that follow: The most important reason for
this state of affairs, perhaps, is that India was the only country in the world to truly recognize the
achievements of the Soviet Union-rather than merely focus on the debilitating faults that Communism
brought to its people. The people of India realized that the achievement of one hundred percent
literacy in a country much, much larger than its own and with similarly complicated ethnic and religious
groupings, the rapid industrialization of a nation that was a primarily agrarian society when the
Bolshevik revolution took place in 1917, the attendant revolutionary steps in science and technology, the
accessibility of health care (primeval according to Western standards, perhaps, but not according to
Indian ones) to the general population, and despite the prohibition of the government of the time the
vast outpourings in literature, music, art, etc. are momentous and remarkable feats in any country. In
contrast, all that the West focused on were the massive human rights violations by the Soviet State on
its people, the deliberate uprooting and mass migrations of ethnic peoples from one part of the
country to another in the name of industrialization, the end of religion. In short, all the tools of
information were employed to condemn the ideology of Communism, so much at variance with
capitalist thinking. The difference with the Indian perception, I think here is, that while the Indians
reacted as negatively to what the Soviet governments did to its people in the name of good
governance (witness the imprisonment of Boris Pasternak and the formation of an international
committee to put pressure for his release with Jawaharlal Nehru at its head), they took the pain not to
condemn the people of that broad country in black and white terms; they understood that mingled in
the shades of grey were grains of uniqueness (The Russians have never failed that characteristic in
themselves; they have twice experimented with completely different ideologies, Communism and
Capitalism both in the space of a century).
The West did not focus on:

rapid growth of nuclear weapons in russia
 

 

3.

For some days the new professor lectured above the heads of his pupils
over the head of
over the heads of
on the heads of
through the heads of
 

 

4.

Inertia-gravity waves cause characteristic stripy patterns in the clouds in the lower atmosphere but
they are disregarded by conventional weather forecasts because they are thought to be too small
to interact with larger systems such as warm and cold fronts.
they are disregarded by conventional weather forecasts because they are thought to be too small
they are disregarded by conventional weather forecasts because these waves are thought to be
too small
conventional weather forecasts think them too small
conventional weather forecasts disregard them because they think they are too small
conventional weather forecasts disregard these waves because they are thought to be too small
 

 

5.

Directions Study the paragraph and answer the questions that follow: The most important reason for
this state of affairs, perhaps, is that India was the only country in the world to truly recognize the
achievements of the Soviet Union-rather than merely focus on the debilitating faults that Communism
brought to its people. The people of India realized that the achievement of one hundred percent
literacy in a country much, much larger than its own and with similarly complicated ethnic and religious
groupings, the rapid industrialization of a nation that was a primarily agrarian society when the
Bolshevik revolution took place in 1917, the attendant revolutionary steps in science and technology, the
accessibility of health care (primeval according to Western standards, perhaps, but not according to
Indian ones) to the general population, and despite the prohibition of the government of the time the
vast outpourings in literature, music, art, etc. are momentous and remarkable feats in any country. In
contrast, all that the West focused on were the massive human rights violations by the Soviet State on
its people, the deliberate uprooting and mass migrations of ethnic peoples from one part of the
country to another in the name of industrialization, the end of religion. In short, all the tools of
information were employed to condemn the ideology of Communism, so much at variance with
capitalist thinking. The difference with the Indian perception, I think here is, that while the Indians
reacted as negatively to what the Soviet governments did to its people in the name of good
governance (witness the imprisonment of Boris Pasternak and the formation of an international
committee to put pressure for his release with Jawaharlal Nehru at its head), they took the pain not to
condemn the people of that broad country in black and white terms; they understood that mingled in
the shades of grey were grains of uniqueness (The Russians have never failed that characteristic in
themselves; they have twice experimented with completely different ideologies, Communism and
Capitalism both in the space of a century). The passage is

analytical

 

6.

Select the word or phrase which is nearly opposite in meaning to the given word.
EXTRAORDINARY(OPPOSITE)
Exceptional
remarkable
Spectacle
Common

 

7.

Federal efforts to aid minority businesses began in the 1960’s when the Small Business Administration
(SBA) began making federally guaranteed loans and government-sponsored management and
technical assistance available to minority business enterprises. While this program enabled many
minority entrepreneurs to form new businesses, the results were disappointing, since managerial
inexperience, unfavorable locations, and capital shortages led to high failure rates. Even 15 years after
the program was implemented, minority business receipts were not quite two percent of the national
economy’s total receipts. Recently federal policymakers have adopted an approach intended to
accelerate development of the minority business sector by moving away from directly aiding small
minority enterprises and toward supporting larger, growth-oriented minority rms through intermediary
companies. In this approach, large corporations participate in the development of successful and
stable minority businesses by making use of government-sponsored venture capital. The capital is
used by a participating company to establish a Minority Enterprise Small Business Investment
Company or MESBIC. The MESBIC then provides capital and guidance to minority businesses that have
the potential to become future suppliers or customers of the sponsoring company. MESBIC’s are the
result of the belief that providing established rms with easier access to relevant management
techniques and more job-specific experience, as well as substantial amounts of capital, gives those
rms a greater opportunity to develop sound business foundations than does simply making general
management experience and small amounts of capital available. Further, since potential markets for
the minority businesses already exist through the sponsoring companies, the minority businesses face
considerably less risk in terms of location and market actuation. Following early financial and operating
problems, sponsoring corporations began to capitalize MESBIC’s far above the legal minimum of
$500,000 in order to generate sufficient income and to sustain the quality of management needed.
MESBIC’s are now emerging as increasingly important financing sources for minority enterprises.
Ironically, MESBIC staffs, which usually consist of Hispanic and Black professionals, tend to approach
investments in minority rms more pragmatically than do many MESBIC directors, who are usually senior
managers from sponsoring corporations. The latter often still think mainly in terms of the “social
responsibility approach” and thus seem to prefer deals that are riskier and less attractive than normal
investment criteria would warrant. Such differences in viewpoint have produced uneasiness among
many minority staff members, who feel that minority entrepreneurs and businesses should be judged
by established business considerations. These staff members believe their point of view is closer to
the original philosophy of MESBIC’s and they are concerned that, unless a more prudent course is
followed, MESBIC directors may revert to policies likely to re-create the disappointing results of the
original SBA approach.
 

attempt to maintain ..........................

 

8.

Mary became __ at typing because she practiced every day for six months.
proficient
reflective
valiant
dormant
redundant

 

9.

Environmentalists associated with the United Nations Environment program predict that if the current
trends associated with global warming continue, thousands of acres of pristine land is in danger to
undergo potentially irrevocable changes that could alter the planet's ecosystem forever.
is in danger to undergo
are in danger of undergoing
is in the danger of undergoing
is in danger of undergoing
are in danger for undergoing

 

10.

Arrange the following sentences in a proper order to make a meaningful paragraph.
1). His political career came to an abrupt end with China's military operation.
2). He attracted as as repelled.
3). He was responsible for the debacle
.4). A man of paradoxes, Menon remained an enigma
4312
1342
4213
4132
 

 

11.

Phillip’s __ tone endeared him to his comical friends but irritated his serious father.
aloof
jesting
conservative
grave
earnest

 

12.

In the initial stages of learning a new language, we learn more through listening and attempting to copy
speech patterns and not through reading grammar books.
and attempting to copy speech patterns and not through reading grammar books
and attempting to copy speech patterns than through reading grammar books.
and attempts to copy speech patterns than through reading grammar books.
and attempt at copying speech patterns and not grammar book
 

 

13.

Directions Study the paragraph and answer the questions that follows:
The most important reason for this state of affairs, perhaps, is that India was the only country in the
world to truly recognize the achievements of the Soviet Union-rather than merely focus on the
debilitating faults that Communism brought to its people. The people of India realized that the
achievement of one hundred percent literacy in a country much, much larger than its own and with
similarly complicated ethnic and religious groupings, the rapid industrialization of a nation that was a
primarily agrarian society when the Bolshevik revolution took place in 1917, the attendant revolutionary
steps in science and technology, the accessibility of health care (primeval according to Western
standards, perhaps, but not according to Indian ones) to the general population, and despite the
prohibition of the government of the time the vast outpourings in literature, music, art, etc. are
momentous and remarkable feats in any country. In contrast, all that the West focused on were the
massive human rights violations by the Soviet State on its people, the deliberate uprooting and mass
migrations of ethnic peoples from one part of the country to another in the name of industrialization,
the end of religion. In short, all the tools of information were employed to condemn the ideology of
Communism, so much at variance with capitalist thinking. The difference with the Indian perception, I
think there is, that while the Indians reacted as negatively to what the Soviet governments did to its
people in the name of good governance (witness the imprisonment of Boris Pasternak and the
formation of an international committee to put pressure for his release with Jawaharlal Nehru at its
head), they took the pain not to condemn the people of that broad country in black and white terms;
they understood that mingled in the shades of grey were grains of uniqueness (The Russians have
never failed that characteristic in themselves; they have twice experimented with completely different
ideologies, Communism and Capitalism both in the space of a century).
Which of the following statements according to the passage is correct?

India seriously commended....................................

 

14.

Directions Study the paragraph and answer the questions that follow: The most important reason for
this state of affairs, perhaps, is that India was the only country in the world to truly recognize the
achievements of the Soviet Union-rather than merely focus on the debilitating faults that Communism
brought to its people. The people of India realized that the achievement of one hundred percent
literacy in a country much, much larger than its own and with similarly complicated ethnic and religious
groupings, the rapid industrialization of a nation that was a primarily agrarian society when the
Bolshevik revolution took place in 1917, the attendant revolutionary steps in science and technology, the
accessibility of health care (primeval according to Western standards, perhaps, but not according to
Indian ones) to the general population, and despite the prohibition of the government of the time the
vast outpourings in literature, music, art, etc. are momentous and remarkable feats in any country. In
contrast, all that the West focused on were the massive human rights violations by the Soviet State on
its people, the deliberate uprooting and mass migrations of ethnic peoples from one part of the
country to another in the name of industrialization, the end of religion. In short, all the tools of
information were employed to condemn the ideology of Communism, so much at variance with
capitalist thinking. The difference with the Indian perception, I think there is, that while the Indians
reacted as negatively to what the Soviet governments did to its people in the name of good
governance (witness the imprisonment of Boris Pasternak and the formation of an international
committee to put pressure for his release with Jawaharlal Nehru at its head), they took the pain not to
condemn the people of that broad country in black and white terms; they understood that mingled in
the shades of grey were grains of uniqueness (The Russians have never failed that characteristic in
themselves; they have twice experimented with completely different ideologies, Communism and
Capitalism both in the space of a century).
India perception of the USSR was always

applauding

 

15.

Prince Phillip had to choose: marry the woman he loved and __ his right to the throne, or marry Lady
Fiona and inherit the crown.
reprimand
upbraid
extol
abdicate
winnow

 

16.

Neem has ___ qualities and in many clinical trials, doctor have saved countless lives by using raw Neem
leaves on serious wounds.
notorious
flavouring
remedial
inferior
doubtful

 

17.

Despite being thousands of years old, the writing of Augustine of Hippo has inspired and captivated
countless individuals, fundamentally because they convey the moving inner-journey of a man
searching for the divine in a lucid and compelling fashion
because they convey the moving inner-journey
due to the fact that it conveys the moving inner-journey
because of their conveying the moving inner-journey
because it conveys the moving inner-journey
 

 

18.

Over the years the Wilsons slowly __ upon the Jacksons’ property, moving the stone markers that
divided their lots farther and farther onto the Jacksons’ land.
encroached
jettisoned
teemed
conjoined
repudiated
 

 

19.

Federal efforts to aid minority businesses began in the 1960’s when the Small Business Administration
(SBA) began making federally guaranteed loans and government-sponsored management and
technical assistance available to minority business enterprises. While this program enabled many
minority entrepreneurs to form new businesses, the results were disappointing, since managerial
inexperience, unfavorable locations, and capital shortages led to high failure rates. Even 15 years after
the program was implemented, minority business receipts were not quite two percent of the national
economy’s total receipts. Recently federal policymakers have adopted an approach intended to
accelerate the development of the minority business sector by moving away from directly aiding small
minority enterprises and toward supporting larger, growth-oriented minority rms through intermediary
companies. In this approach, large corporations participate in the development of successful and
stable minority businesses by making use of government-sponsored venture capital. The capital is
used by a participating company to establish a Minority Enterprise Small Business Investment
Company or MESBIC. The MESBIC then provides capital and guidance to minority businesses that have
the potential to become future suppliers or customers of the sponsoring company. MESBIC’s are the
result of the belief that providing established rms with easier access to relevant management
techniques and more job-specific experience, as well as substantial amounts of capital, gives those
firms a greater opportunity to develop sound business foundations than does simply making general
management experience and small amounts of capital available. Further, since potential markets for
the minority businesses already exist through the sponsoring companies, the minority businesses face
considerably less risk in terms of location and market situation. Following early financial and operating
problems, sponsoring corporations began to capitalize MESBIC’s far above the legal minimum of
$500,000 in order to generate sufficient income and to sustain the quality of management needed.
MESBIC’s are now emerging as increasingly important financing sources for minority enterprises.
Ironically, MESBIC staffs, which usually consist of Hispanic and Black professionals, tend to approach
investments in minority rms more pragmatically than do many MESBIC directors, who are usually senior
managers from sponsoring corporations. The latter often still think mainly in terms of the “social
responsibility approach” and thus seem to prefer deals that are riskier and less attractive than normal
investment criteria would warrant. Such differences in viewpoint have produced uneasiness among
many minority staff members, who feel that minority entrepreneurs and businesses should be judged
by established business considerations. These staff members believe their point of view is closer to
the original philosophy of MESBIC’s and they are concerned that, unless a more prudent course is
followed, MESBIC directors may revert to policies likely to re-create the disappointing results of the
original SBA approac

 The use of mesbic's ...................................................................................

20.

Select the word or phrase which best expresses the meaning of the given word. PROFUSE
Defuse
Ample
Declare
Flimsy
Accept

 

21.

Despite the influx of international aid to a particularly war-torn region of East Africa during the waning
months of 2006, in early 2007, many indigenous people unable to nd food left their home to travel
west where other tribal groups historically experienced less difficulties producing food, water, and
land.
their home to travel west where other tribal groups historically experienced less difficulties
home to travel west where other tribal groups historically experienced fewer difficulties
home to travel west where other tribal groups historically had experienced fewer difficulties
their home to travel west where other tribal groups historically experienced fewer difculties

 

22.

Nandni soon discovered the source of the __ smell in the room: a week-old tuna sandwich that one of
the children had hidden in the closet.
quaint
fastidious
fetid
clandestine
laconic
 

--------------------------------------------------------------------------------------------------------------------------

 

Post a Comment

Previous Post Next Post