KnowledgeBoat Logo
|

Computer Science

Which one of the following if statements will not execute successfully ?

  1. if (1, 2) : <br/>&nbsp;&nbsp;&nbsp;&nbsp;print('foo')
  2. if (1, 2) <br/>&nbsp;&nbsp;&nbsp;&nbsp;print('foo')
  3. if (1, 2) : <br/>print('foo')
  4. if (1) : <br/>&nbsp;&nbsp;&nbsp;&nbsp;print( 'foo' )

Python Control Flow

25 Likes

Answer

if (1, 2) <br/>&nbsp;&nbsp;&nbsp;&nbsp;print('foo')

if (1, 2) : <br/>print('foo')

Answered By

5 Likes


Related Questions