Use Coupon: CART20 and get 20% off on all online Study Material

Total Price: R

There are no items in this cart.
Continue Shopping
Get instant 20% OFF on Online Material.
coupon code: MOB20 | View Course list

  • Complete Physics Course - Class 11
  • OFFERED PRICE: R 2,800
  • View Details
Get extra R 700 off


Most Urgent C++ Problems --

Give definitions of the following : -

a)simple if




Please give only and only definitions.No examples nothing else.

6 years ago


Answers : (2)


Dear nitin,

  if ( TRUE ) Execute the next statement

if ( TRUE ) {

// Execute these statements if TRUE
else {
// Execute these statements if FALSE

if ( <condition> ) {

// Execute these statements if <condition> is TRUE
else if ( <another condition> ) {
// Execute these statements if <another condition> is TRUE and
// <condition> is FALSE

The switch statement provides a convenient alternative to the if when dealing with a multi-way branch. Suppose we have some integer value called test and want to do different operations depending on whether it has the value 1, 5 or any other value, then the switch statement could be employed:-
switch ( test ) {

case 1 :
// Process for test = 1

case 5 :
// Process for test = 5

default :
// Process for all other cases.


Please feel free to ask your queries here. We are all IITians and here to help you in your IIT JEE preparation.
All the best.
Win exciting gifts by answering the questions on Discussion Forum. So help discuss any query on askiitians forum and become an Elite Expert Leagueaskiitian.
Now you score 5+15 POINTS by uploading your Pic and Downloading the Askiitians Toolbar  respectively : Click here to download the toolbar..

Askiitians Expert
Sagar Singh
B.Tech, IIT Delhi 

6 years ago

I got the definition of switch statement from your answer.But what can I write in the definition of simple if,if-else,if-else-if?There is no need to give examples.I know these things but just don't know the definition.

Thanks for you replies in this and other questions

6 years ago

Post Your Answer

Other Related Questions on Mechanics

Solve this question urgently . This question your challenge you answer with solution
Vivek please share the question so that someone be able to answer the question.There is no attachment either..................
Mudit 2 months ago
Hi friend , sorry friend there is no question. Please add attach ok thanks. please upload question or attach image
A spring of force constant k is cut into 2 pieces such that one piece is double the length of the other. Then the longer piece will have force constant1)2/3k 2)3/2k 3)3k 4)6k
I think the answer is 2/3 k according to Young’s Modulous. If correct please approve my answer otherwise let me know.
Mudit 2 days ago
Four particles A,B,C and D of equal mass move with equal speed v along the diagonals of a square in a horizontal plane. After the collision, A comes to rest while B and C retrace their...
Conserve the momentum in x-direction and y-direction for each masses respectively. And U would get the relation. In x direcn. the Vd = 2v i cap. find similarly in y-direcn.
Vikas TU 2 months ago
Can you please solve the question fully and post the answer? ….........................................................................................
Divya one month ago
short note on ohmic and non ohmic substances with proper example
@kishor ohmic substances – these are purely conducter which obey ohms law at every temp , and pressure range . temp and pressure are kept as low and constant here . example – copper ,...
Umakant biswal one month ago
what is meant by electrostatic force?give example for electrostatic force
Hii It’s the force exerted by two static charged particles containing non zero charges. Example ,Paper strips attracted by a charged CD
Sourabh Singh 9 months ago
If the two charges have the same sign, the electrostatic force between them is repulsive; if they have different sign, the force between them is attractive. An electric field is a vector...
Prabhakar ch 8 months ago
Electro static is the phenomenon arise from the forces that electric charges exert on each other.or it is an electric field that associates to each point in the coloumb force.
N JYOTHEESWAR 8 months ago
3 point charges lie along a straight line with positive charge at the centre and negetive at the ends all are ‘a’ distance apart from each other. The energy needed to exchange the position...
Let the charges be -q, +q and -q. Distance between two charges = a Energy of the system putting the values we get U initial = Final energy of the system, U final = Therefore, work required...
Raman Mishra one month ago
View all Questions »

  • Complete Physics Course - Class 12
  • OFFERED PRICE: R 2,600
  • View Details
Get extra R 650 off

  • Complete Physics Course - Class 11
  • OFFERED PRICE: R 2,800
  • View Details

Get extra R 700 off

More Questions On Mechanics

Ask Experts

Have any Question? Ask Experts

Post Question

Answer ‘n’ Earn
Attractive Gift
To Win!!!
Click Here for details