A class consists of 3 students from Ashville and 4 from Bewton. A committee of 5 students is
chosen at random the class.a. Find the number of committees that include 2 students from Ashville and 3 from Bewton
are chosen.
b. In fact 2 students, from Ashville and 3 from Bewton are chosen. In order to watch a video,
all 5 committee members sit in a row. In how many different orders can they sit if no two
students from Bewton sit next to each other.
By both generating and directly computing obtain the number of the following:
a. All permutations of (0,1,2,3,4,5).
b. All permutations of ("A","B","C").
c. Permutations of size 3 of (0,1,2,3,4,5).
d. Permutations of size 2 of (0,1,2,3,4,5,6).
e. Combinations of size 3 of (0,1,2,3,4,5).
f. Combinations of size 2 of (0,1,2,3,4,5).
g. Combinations of size 5 of (0,1,2,3,4,5)
Write down a python code to generate 3 sets of lottery tickets randomly from the pool of 300
tickets with an equal probability distribution, and keep in mind that if a set of the number already
selected in the first-month lottery, the same number is not allowed to repeat.
Right Triangle
Given a number N write a program to print a triangular pattern of N lines with the number as shown below
1
121
12321
1234321
1. Create an application named Numbers whose main() method holds two integer variables. Assign
values to the variables. Pass both variables to methods named sum () and difference(). Create the
methods sum() and difference(); they compute the sum of and difference between the values of two
arguments, respectively. Each method should perform the appropriate computation and display the
results. Save the application as Numbers.cs
Write an application for a furniture company; the program determines the price of a table. Ask the user to choose 1 for pine, 2 for oak, or 3 for mahogany. The output is the name of the wood chosen as well as the price of the table. Pine tables cost R 100, oak tables cost R 225, and mahogany tables cost R 310. If the user enters an invalid wood code, set the price to 0 and allow the user to select an option up to 3 times . Save the file as Furniture.java.
Marks allocation
1. Presentation of a menu - 10
Select an option
1. for pine
2. for oak
3. for mahogany
2. use of a loop - 10
3. Use of an if statement/ switch - 10
4. correct output -10
Create a program with two methods, one method for displaying your full name and the
other method displays your address.
Requirements:
The menu is shown below:
1 – Balance Inquiry
2 – Withdraw
3 – Deposit
X – Exit
Score will be updated before encoded in BBL for the following:
Input
1. data
Output
Enter·pin:·123489
1·–·Balance·Inquiry
2·–·Withdraw
3·–·Deposit··
X·–·Exit
Enter·your·choice:··X
Thank·you·for·banking·with·us!
Create a PHP page, with the standard HTML ,
and <body> tags.<br/><br/><br/>Save your file with the .php extension.<br/><br/><br/>Inside the <body> tag, create a PHP section and create<br/>several variables regarding on the student information example<br/>Student_FirstName, Student_MiddleName, Student_Lastname, address, course, year, and motto will show as a text in the browser.<br/>
Create a PHP page, with the standard HTML <head>,
<title> and <body> tags.
Save your file with the .php extension.
Inside the <body> tag, create a PHP section and create
several variables regarding on the student information example
Student_FirstName, Student_MiddleName, Student_Lastname, address, course, year, and motto will show as a text in the browser.