Wednesday 26 January 2022

Python practice programs for beginners - Day1

 

Python practice programs for beginners - Millioninformations


Welcome to the 30-day challenge of Python practising for beginners.


Python practice programs for beginners - Day1


Variables:

Variables are the most important concept in any programming language. It will help to store any data which we can use throughout the program.

Example: userName="millioninformations"

userName is the variable name and "millioninformations" is the value stored in that variable.

Rules for declaring Variables:

1.Variable must start with lowercase letter
2. Should not contain space or special characters.
3. Underscore can be used to connect two words
4. Also can follow camelCase (first words first letter in lower case and second words first letter in upper case)

Practice Program - Day 1

Write a Program to store a Student's details using the below variable names:

--> studentName
--> studentAge
--> studentGender
--> institute


Sample output:



Try to complete the task.

The output will be displayed in the next post.

If you are reading this post for the first time do read: 

No comments :

Post a Comment