python lab questions 1-75 pages

Base Conversions :

     1.Convert any  number to Binary

     2.Convert any  number to Octal

     3.Convert any  number to Hexadecimal


Type Casting :

  1. Convert values from other types to int.

  2. Convert values from other types to float.

  3. Convert values from other types to complex.

  4. Convert values from other types to boolean.

  5. Convert values from other types to string.


Special Datatype :

  1. Write a program on list datatype.

  2. Write a program on tuple datatype.

  3. Write a program on dictionary datatype.

  4. Write a program on none  datatype.

  5. Write a program on range datatype.

  6. Write a program on set datatype.

  7. Write a program on frozenset datatype.

  8. Write a program on byte  datatype.

  9. Write a program on bytearray datatype.

Escape Characters :

    1.Write a program on Escape Characters.

Operators :

           1.Write a program on Arithmetic operators.

           2.Write a program on Relational operators.

           3.Write a program on Equality operators.

           4.Write a program on Logical operators.

   5.Write a program on Bitwise operators.

           6.Write a program on Shift operators.

           7.Write a program on Assignment operators.

           8.Write a program on Ternary operators.

           9.Write a program on Identity operator

         10.Write a program on Membership operators.

         11.Write a program on Minimum of three numbers

         12.Write a program on Maximum of three numbers


         Input/ Output Statements :


           1 .Write a program on raw input.

      2.Write a program to read 2 numbers from the keyboard and print sum.

       3. Write a program to read Employee data from the keyboard and

          print that data.

           4. How to read multiple values from the keyboard in a single line

           5. Write a program to read 3 float numbers from the keyboard 

               with  separator and print their sum.

           6. Write a program on  Eval () input.

Transfer Statements :

    1.write a program on  break statement.

    2.To print odd numbers in the range 0 to 9 on continue statement

Command Line Arguments :

  1. Write a Program to display the Command Line Argument.

  2. usually space is separator between command line arguments.

  3. Within the Python program command line arguments are available in the String form.

  4. : If we are trying to access command line arguments with out of range index then we will get Error.


Conditional Statements :

  1. Write a program on if statement.

  2. Write a program on if  else statement

  3. Write a program on if elif else statement.

  4. Write a program to find biggest of given 2 numbers from the commad prompt

  5. Write a program to find biggest of given 3 numbers from the commad prompt?

  6. Write a program to take a single digit number from the key board and print is value in English word?

  7. Write a program to find smallest of given 2 numbers?

  8. Write a program to find smallest of given 3 numbers?

  9. Write a program to check whether the given number is even or odd?

  10. Write a program to check whether the given number is in between 1 and 100

Iterative statements :

  1. Write a program on for- loop

  2. To print characters present in the given string

  3. To print characters present in string index wise

  4. To print Hello 10 times

  5. To display numbers from 0 to 10

  6. : To display odd numbers from 0 to 20

  7. To display numbers from 10 to 1 in descending order

  8. To print sum of numbers presenst inside list

  9. To print numbers from 1 to 10 by using while loop

  10. To display the sum of first n numbers

  11. write a program to prompt user to enter some name until entering Durga

  12. write a program on Nested loops

  13. write a program on Infinite  loops

  14. Write a program to dispaly *'s in Right angled triangled form

  15. Write a program to display *'s in pyramid style(also known as equivalent triangle

String Data Type :

  1. Write a program to accept some string from the keyboard and display its characters by index wise(both positive and negative index)

  2. Write a program to access each character of string in forward and backward direction by using while loop?

  3. Write a program on comparison of strings.

Slicing of strings :

1.Write a program on string slicing perform various slicing operations


Comments

Popular posts from this blog

DMGT notes