In this blog we will provide some basic to advance level python programming sample papers. You need to solve it and comments in below comment section and paste your solution if you need any help related to python programming assignments, python programming homework and python programming project then send your requirement details at realcode4you@gmail.com and get instant help with an affordable price.
Sample Practice Paper 1(Salary Schedule)
ALIGNMENT: This assignment provides practice with using a repetition structure to print a salary schedule.
ASSIGNMENT: Acme Widgets, Inc. values its loyal employees and strives to keep them long-term. Salaried employees earn a 2.75% cost-of-living increase (on current salary) plus a salary increase of $2350 in base pay each year on their hiring date anniversary. Write an original Python program that seeks input of the employee’s name, their starting salary (year one) and the number of years the plan to work. It should then show a salary schedule showing the adjustments discussed above each year (a 2.75% increase, plus a $2350 increase in base pay [the 2.75% should be applied before the $2350]. It should also display the total earned for all those years in the employee’s base pay:
Output sample 1:
Output sample 2:
Write a Python program in which you:
Save your file with as “CIS156_03D_WageSteps_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
The user should be prompted to enter a strings containing name., starting salary, and number of years.
TIP: Use a repetition loop (for) to go through each of the anticipated years, e.g.: for xyz in range(1,years + 1): # +1 since the upper num is exclusive Within the loop print the year and adjusted salary for that year, and increment the total earned
After the loop, print the total earned
You may not use any features not yet covered in this course or discussed above, including lists, tuples, functions
Sample Practice Paper 2(BINGO Card Maker )
ALIGNMENT: The purpose of this assignment is to provide practice with while loops and random numbers.
ASSIGNMENT: Write an original Python program that randomly builds and displays a BINGO card! The ranges for the B, I, N, G, and O columns:
five numbers between 1 and 15 (inclusive) for the B column
five numbers between 16 and 30 (inclusive) for the I column
four numbers between 31 and 45 (inclusive) for the N column (middle space is "FREE") - five numbers between 46 and 60 f(inclusive) or the G column
five numbers between 61 and 75 f(inclusive) or the ) column Of course there should be no duplicates values!
Save your file with as “CIS156_04A_BingoCard_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
RESTRICTION; Your solution can only utilize the statements we discussed in class thus far: variables, print(), input(), int(), math operations, and of course conditionals and repetitions. I did not use lists or dictionaries in my solutions, but you may if you wish. Oh, and use comments in your code!
Any additional features such as def (functions), built-in or custom methods, etc. will not be recognized as a solution and would likely be indicative of a solution found on the internet! No points given!
Display the results in a graphical columnar output as shown at the right (you may have to play around with print statements a bit!)
Output sample 1:
Output sample 2:
Sample Practice Paper 3(Monopoly Rolls )
ALIGNMENT: The purpose of this assignment is to provide practice while loops using sentinels as well as utilizing a Data Structure (list, tuple or dictionary).
ASSIGNMENT: Write an original Python program that allows the user to simulate rolling a pair of dice and using the rolled value to move around a virtual Monopoly game board. The student starts on the Go space. As you go back around the board (past Go) you will need to use modulus operations to recalculate the square the user lands on. I.e. there are only 40 squares, 0- 39 (0 is “Go” and 39 is “BoardWalk”). For example if the user is on ParkPlace (square 37) and rolls a 5, they should proceed to square 2 (“Community Chest”) – how do you get them there? This is again where modulus operations can save the day (And I know you all though when you saw modulus, you asked “When would I ever use it?” – we have now used it a bunch of times!). To solve this we can add the roll to our current location (variable: current) from the previous roll and then set the value of current to the remainder of an integer division by 40:
current += total
current = current % 40 So,
if current is 37 and total roll is 5, current becomes 42 (i.e. 37 + 5), and the modulus operation of 42 % 40 yields a new value of current as 2. Square 2 is “Community Chest”. We’ve just gone around the board! You can also do these operation as one statement:
current = (current + total) % 40
If you need help with the Monopoly board layout – above is a graphic to help (derived from the Creative-commons licensed https://en.wikipedia.org/wiki/Template:Monopoly_board_layout (I added numbers for to reference the Indices of our data structure).
Use an input value to gather input (can be just the Enter key to proceed to the next roll. Your project will use a while loop and a sentinel value (e.g. the player enters X to end the application) to exit the loop. As long as they do not enter an X, they keep rolling.
Save your file with as “CIS156_04C_Monop-ly_Rolls_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
RESTRICTION; Your solution can only utilize the statements we discussed in class thus far: variables, print(), input(), int(), math operations, conditionals, repetition structures, list, tuples or dictionaries!
Any additional features such as def (functions), built-in or custom methods, etc. will not be recognized as an acceptable solution.
Display the results as shown in the example below:
Output sample 1:
Output sample 2:
Sample Practice Paper 4(Multiplication Table)
ALIGNMENT: The purpose of this assignment is to provide practice with nested loops (and some basic math).
ASSIGNMENT: Write an original Python program that askes the user to enter two integers for creating a multiplication table. One integer would be the starting column value (of 5 subsequent values) and the other would be the starting row value of 5 subsequent values. The program then builds a printed multiplication table of the values in a 5x5 grid.
Save your file with as “CIS156_04D_Multiplication_Table_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
RESTRICTION; Your solution can only utilize the statements we discussed in class thus far: variables, print(), input(), int(), math operations, and of course conditionals and repetitions. I did not use lists or dictionaries in my solutions, but you may if you wish. Oh, and use comments in your code!
Any additional features such as def (functions), built-in or custom methods, etc. will not be recognized as a solution and would likely be indicative of a solution found on the internet! No points given!
Display the results in a graphical columnar output as shown at the right (you may have to play around with print statements a bit!
Output sample 1:
Output sample 2:
Output sample 3:
Sample Practice Paper 5(Generation Classifier)
ALIGNMENT: The purpose of this assignment is to provide practice with if..elif..else structures
ASSIGNMENT: The following table represents the Western Cultural Generations:
Write a Python program that asks the user for their name and the year they were born. The display a message containing their name, birth year and the generation name (see examples below):
Save your file with as “CIS156_02A_Generations_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
The user should be prompted to enter their name and then prompted to enter their birth year (yyyy).
Use an if..elif..else conditional structure to determine which generation category the person fits into based on their year of birth
If the year is less than 1910 or greater than 2025, output a message that the year is invalid. See last two examples)
Output a string showing the user’s name, year of birth and their generation classification, such as “Paul, being born in 1987, puts you in Generation Y [Millennials; Gen Next] (1980-1994).” See example below.
Output sample 1:
Output sample 2:
Sample Practice Paper 6(Olympic Judging)
ALIGNMENT: The purpose of this assignment is to provide practice with if structures. ASSIGNMENT: Olympic Judging of subjective events such as ice skating and gymnastics is performed by a panel of judges from various nations. To thwart any bias, the low and high score are removed and the remaining scores are averaged to determine the judged score. Write a Python program that asks the user to enter a score between 0.0 and 10.0 for each of seven national judges, China, France, Germany, Great Britain, Sweden, United States, and Zimbabwe. The display a message containing their name, birth year and the generation name (see examples below):
Save your file with as “CIS156_02B_Olympic_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
After gathering the seven scores for the seven national judges, your program should determine which nations had the low and high scores and then find the average of the remaining five.
The output should show the low and high scores (along with the countries) and the average of the middle five as shown below. Show the average as a formatted float with two decimals.
Output Sample 1:
Output Sample 2:
Output Sample 3:
TIP: Use sequential if structure to compare each nation’s score to the current high and low values. Set high and low as needed. Don’t make this harder than it needs to be…Don’t try to compare all the judges in a complex Boolean (using ands).Just compare high and low to each country. Create a solution that could easily be extended if there were more judges added!
TIP: PSEUDOCODE FOR LOW:
Set the low score to China and the low_country to China.
If France score is lower than low, then set low to France score and the low_country to France
If Germany score is lower than low, then set low to Germany score and the low_country to Germany
Continue process for Great_Britain, Sweden, United States and Zimbabwe. Do a similar process for the high and high_country values.
To determine the average
Take the sum of all seven scores
Subtract the low and high scores
Divide the result from step 2 by 5.0 to determine the average. BTW, I give the same assignment to my C# class (CIS162AD). Watch the video at https://youtu.be/Dg9N_1hdRFg.
Sample Practice Paper 7(Roulette Wheel Colors )
ALIGNMENT: The purpose of this assignment is to provide practice with if…elif…else structures, and possibly modulus operations to (determine if a number is even or odd).
ASSIGNMENT: In the gambling game of Roulette, a wheel is spun with a ball landing in one of 37 pockets, numbered 0 through 36. Each pocket (number) is associated with a color of red, black or green. The following represents the relationship of the colors to the numbers:
For numbers 1 through 10, the odd numbers are red and the even numbers are black.
For numbers 11 through 18, the odd numbers are black and the even numbers are red.
For numbers 19 through 28, the odd numbers are red and the even numbers are black.
For numbers 29 through 36, the odd numbers are black and the even numbers are red.
For number 0, it is green!
Write a Python program that asks the user to enter the number (int) and display whether that number is red, black or green. See sample output below.
Save your file with as “CIS156_02C_Roulette_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
Have the user enter a number between 0 and 36.
Display the color associated with the number. If the number is less than 0 or greater than 36, display an error message (see last two sample data images below).
Output Sample 1:
Output Sample 2:
Sample Practice Paper 8(Binary to Decimal to Hex )
ALIGNMENT: The purpose of this assignment is to provide practice with nested if…elif…else structures, and integer division and modulus operations.
ASSIGNMENT: Write an original Python program that converts a single byte value (decimal 0-255 range) for each of the following operations (chosen by the user):
Convert a Decimal value (0-255) to its Binary equivalent (00000000 – 11111111).
Convert a Binary value (00000000 – 11111111) to its Decimal equivalent.
Convert a Decimal value (0 – 255) to Hexadecimal equivalent (00 – FF).
Convert a Hexadecimal value (00 – FF) to its decimal equivalent (0 – 255)
Save your file with as “CIS156_02D_Binary2Dec2Hex_YourLastName.py”
Print the project tile on the first line. Print the next line showing your name as the developer, followed by a blank line (remember you can use \n). Then provide a description of what the program does.
You will use nested if…elif structures. The outer if…elif wil be for the operation the user chooses (A, B, C, or D) as well as an else that should catch any other user choice and provide an “error” message. Then inside each operation fork, you will likely utilize one or more if…else or if…elif…else structures.
Inside each operation, also check that the input is in the correct range and provide an error message if not before terminating.
RESTRICTION; Your solution can only utilize the statements we discussed in class thus far: variables, print(), input(), int(), math operations, string methods (you might find the .[idx] method of a string handy in converting decimal to hex) and of course if…elif…else (and its variations including ternary conditionals). Oh, and use comments in your code!
Any additional features such as def (functions), lists, built-in conversion methods, etc. will not be recognized as a solution and would likely be indicative of a solution found on the internet! No points given!
Display the output in string format as shown in the illustrations below.
Output Sample 1:
Output Sample 2:
Output Sample 3:
Send your assignment requirement details at realcode4you@gmail.com to get instant help with an affordable price.
Comments