Skip to content
All Basic Articles
Introduction So far we have been using C language for simple console output only.  Most of us are unaware that using C++, low level graphics… Read More
Given an array arr[0..n-1] of distinct elements and a range [low, high], find all numbers that are in range, but not in array. The missing… Read More
Python programming language provides following types of loops to handle looping requirements. While Loop Syntax : while expression: statement(s) In Python, all the statements indented… Read More
Scanner class in Java supports nextInt(), nextLong(), nextDouble() etc. But there is no nextChar() (See this for examples) To read a char, we use next().charAt(0).… Read More
Consider the following program. Predict the output of it when compiled with C and C++ compilers. void func() {     /* definition */ }    int… Read More
Prerequisites: Yield Keyword and Iterators There are two terms involved when we discuss generators. Generator-Function : A generator-function is defined like a normal function, but… Read More
The first lecture note given during java class is “In java file name and class name should be the same”. When the above law is… Read More
There are three boxes box1, box2 and box3 containing gold, silver and  mixture of silver and gold respectively. Each of the three boxes contain a… Read More
Combinatorial games are two-person games with perfect information and no chance moves (no randomization like coin toss is involved that can effect the game). These… Read More
Gyani baba is fond of giving new theories about stars. He discovered that there are two type of stars in this universe; one “X” type… Read More
If tan (x+y) tan (x-y) = 1, then find tan (2x/3)? (A) 2/√3 (B) 1/2 (C) 1/√2 (D) 1/√3 Answer: (D) Explanation: tanA = cotB,… Read More
What is the maximum value of 5 Sinθ + 12 cosθ? (A) 16 (B) 13 (C) 10 (D) 12 Answer: (B) Explanation: Maximum value =… Read More
Find the sum of series: 1/3, 1/9, 1/27, 1/81…………….. (A) 1/2 (B) 1/3 (C) 1/4 (D) 1/6 Answer: (A) Explanation: Sn=a/(1-r) = (1/3)/(1-1/3) =1/2 Quiz… Read More
Find the sum of series: 1, 3, 9, 27, 81, …………..39 (A) [(1-310)]/(1-3) (B) 18 (C) 10 (D) 20 Answer: (A) Explanation: Sol: Sn=[a(1-rn)]/(1-r) =[1(1-310)]/(1-3)… Read More
Find Arithmetic Mean of series: 2, 2.5, 3, 3. 5, 4, 4. 5……….11 (A) 13/2 (B) 25/8 (C) 19 (D) 22/9 Answer: (A) Explanation: AM… Read More
Find sum of series: 2, 2.5, 3, 3. 5, 4, 4. 5……….11 (A) 120 (B) 123.5 (C) 126.5 (D) 118.5 Answer: (B) Explanation: sum of… Read More
Find the Sum of series: 10, 7, 4, 1, -2 (A) 40 (B) 21 (C) 20 (D) 18 Answer: (C) Explanation: Sum of series =… Read More
Ram and Sita participate in a race of 1000 meters. If Ram gives Sita a start of 200 meters or 20 seconds. In ow much… Read More
If Mohan can give a start of 50 m of distance or 10 s of time to Rohan in a race of 1000 meters. How… Read More
Problem: Three cars, an Alto, a Zen and a Nano were stolen. There are 3 suspects (Arun, Kartik and Varun). Each stole 1 vehicle. Here… Read More