#include<stdio.h> #include<iostream> using namespace std; int main(){ string id; string name; cout<<"Enter ID: "; getline(cin,id); cout<<"Enter Name: "; getline(cin,name); cout<<"\nID: "<<id<<endl; cout<<"Name: "<<name<<endl; string course; cout<<"\nEnter course: "; getline(cin,course); if(course != "comp2002") course.clear(); else course += "Computer Science Department"; cout<<"\nCourse: "<<course<<endl; string college; cout<<"\nEnter College:"; getline(cin,college); if(college == "") college = "College of Science"; cout<<"\nCollege: "<<college<<endl; }
OutPuts:


a. Write a program that reads your id and full name and display. And also display...
Cipher Program Specifications: You are to write a program called, "Cipher123" that reads in an encoded message using the 1-2-3 cipher and returns the decoded message. The program should continue prompting for additional encoded messages until the user chooses to quit the program. When decoding a message, we take the first letter of the first word, the second letter of the second word and the third letter of the third word and concatenate them. We repeat this same process 1-2-3...
Write an SQL statement that will display the Employee ID, full name (all capital) and Job ID of all employees that belong to a department with Department ID 20 and whose Job ID has a substring “rep”.
Using c++ write a program using a class that has data members ID#,NAME, SALARY, YEAR_HIRED. This program must 1) write 10 blank records to a random access file. You must enter data for 4 of these records. 2) allow the user to output the name, salary, hire_date for a selected record 3) allow the user to change the name, salary, or hire_date for a selected record. 4) allow the user to input a complete record to replace one of the...
Use Java programing
Write a program to display information about schools in North Carolina that offer a BS in Computer Science. The data file "NCuniversity Data dat" contains the following information on each line: BS in CS Instate cost Out of state cost int int int double fraction of students who return after first year String name of the school 0-no, 1-yes, 2-online only Expected annual cost for an in-state student Expected annual cost for an out of state student...
This Java program reads an integer from a keyboard and prints it out with other comments. Modify the comments at the top of the program to reflect your personal information. Submit Assignment1.java for Assignment #1 using Gradescope->Assignemnt1 on canvas.asu.edu site. You will see that the program has a problem with our submission. Your program is tested with 4 testcases (4 sets of input and output files). In order to pass all test cases, your program needs to produce the same...
Write a C++ program that produces the following output: /* OUTPUT Enter your age: 21 Enter the last name: Lee Hello Tom Lee. You are 21 years old. Press any key */ Declare an array named: firstName The array is a c_string, i.e., it is a null-terminated character array. The size of the array is 10. Assign a first name to it when it is declared. Declare an array named: lastName The array is a c_string, The size of the...
7.3: The Price is Right Write a program that reads in a price as a String, and then outputs the price in dollars and cents. Name your project PriceRight and create a class called PriceRight.java For this program, you can assume that the user will enter in a price in either 10s or 100s of dollars. The price will never go above 999.99 or below 10.00. Hint: read in the price as a String Hint 2: Use the String methods...
Jubail University College Computer Science & Engineering Department Assessmen Assignment Course Code CS120/C5101 t Type: 1 Semester: 403 Course Title Programming Submission 27-06-2020 Total Points 8 Date Submission Instructions: • This is an individual assignment. • Please submit your program (Java fle) in Blackboard. You can create one java project, named as Assignment1_id and add separate java file for each question. You can name your javá files as 01.02.... etc. • Make sure that you include your student ID name...
In order to do Program 6, Program 5 should be
modified.Program 6-----------------------------------Program 4----------------------------------------------- (abstract class exception handling) Modify program4 to meet the following requirements: I. Make Person, Employee classes to abstract classes. Cl0%) 2. Add an interface interface working with a method teach() (5%) interface working void teach(String course) J 3. Modify Faculty class. (20%) a. a private data field and implement existing b. Modify Faculty class as a subclass of addition to the c. toString or print Info) method to...
Write a program that reads integers ,one per line and displays their sum .Also display all the numbers read ,each with an annotation giving its percentage contribution to the sum. Use a method that takes the entire array as one argument and returns the sum of the numbers in the array. Hint: Ask user the user for the number of integers to be entered, create an array of that length ,and then fill the array with the integers read. A...