Skip to content

pgkm93/PythonBasicControlStructures

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 

Repository files navigation

*** Control Structures in Python***

Tutedude Assignment 2

Task - 1

checking if a numbers is Even or odd

  1. In the program i took number as a variables and assigned user input to that variable.
  2. Here the user given input (means number)is divided by 2 == to "0" .
  3. if this condition is true that number will be even otherwise it's odd numbers.

Task - 2

Sum of Integers from 1 to 50 using a loop

1.Here i took total_sum as a variable and took a range from 1 to 51 (here number 51 is not included in the range).
2.Applied sum function to the range.

Thank you

About

Control Structures in Python

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages