Lab Sheet
Lab Sheet
3. Write a Python program using logical operators to check if a number lies between two
other numbers. Take all three numbers in the input and check the above for the third input.
4. Write a Python program using if-else to find the largest of three numbers.
5. Write a Python program to categorize a given integer as positive, negative, or zero using
an if-elif-else ladder.
6. Using nested if statements, write a Python program to check if a number is both divisible
by 5 and even.
7. Write a Python script using a for loop to print the first 10 natural prime numbers.
8. Using a while loop, write a program that prints the Fibonacci series up to a given number.
9. Write a Python program that breaks out of a loop when a user enters a negative number.