Write one line of code ONLY. Use concatenation to print the variables given below in one line with a space in between: LA = "Artificial" | = "Intelligence" Example Output Artificial Intelligence
Q: Programming Problem 1. Rock, Paper, Scissors This is your traditional rock-paper-scissors game,…
A: Lets see the solution in the next steps
Q: public void setQuantity(int quantity}{ minimum quantity is 10 if invalid set it to 10 if(quantity <…
A: Given: Fill in the blanks.
Q: hat will compute the students average • The user will input the following: Name Math …
A: HI, Since the programming language is not mentioned i used python
Q: Write a program that asks the user for the number of adult and the number of child movie tickets…
A: Answer :- #include <iostream> #include <iomanip> using namespace std; int main() {…
Q: Complete the following program so it performs the following actions 10 times:• Generates a random…
A: import java.util.*;//Create a main class "ReviewQuestion16 public class ReviewQuestion16{ public…
Q: Help me create a selection statement flowchart for this python code print("SEASON APPLICATIONS")…
A:
Q: You are given a positive integer x. Check whether the number x is representable as the amount of the…
A: Here have to determine about the sum of cube programming problem statement.
Q: Write a Program to create 10 object of student which contains given information e.g. name, roll…
A: Required: Write a Program to create 10 object of student which contains given information e.g. name,…
Q: A particular talent competition has 5 judges, each of whom awards a score between 0 and 10 to each…
A: The complete code in python programming language is below:
Q: just need to tell what the code is doing as no 1 is done Briefly comment each of the following…
A: The ask is to explain the given snippet of code.
Q: Question 1[15 pts]: Write a java program to help an employee calculate the price of a product after…
A: this is a simple logical coding question in java the complete code and its output is attached in the…
Q: Problem Description: The international standard letter/number mapping found on the telephone keypad…
A: The pseudocode is as follows:Prompt user for a letter in upper caseReceive the input.Convert the…
Q: teachers(tea) in the college and calculate and display the students to teachers in the…
A: C used to answer this question
Q: Simulate the dice game of lucky sevens. The rules are: roll two dice if the sum equals 7, win $4 if…
A: NOTE : As the question is not specific about which Programming Language is to be used to write the…
Q: letter in "aAeEiIoOuU":
A: #This Python program counts the number of vowels present in the string.#Declares a variable count…
Q: Given the ability to assign a value into a variable, why is it useful to be able to specify an…
A: To assign a variable to a value is something you do in programming It means to put a specific…
Q: In PyCharm, write a program that prompts the user for their name and age. Your program should then…
A: Here I have first of all taken input from the user. Then, I have subtracted the age from 2020 to get…
Q: Description Note: You must use the values given and you must not "hard-code" results. Write a Java…
A: logic:- read n if n>=18 display “person can vote” else display “person cannot vote” end.
Q: Explain the difference between passing a variable by value and passing it by reference.
A: The difference between passing a variable by value and passing it by reference are given below,
Q: You'll write a poem in this program. However, there are two types of poems you'll have to print out:…
A: Actually, Java is a programming language originally developed by James Gosling at Sun Microsystems…
Q: Write a number activity and then circle the circle or square. The input will be in the form (letter…
A: Algorithm - Create a new function with name perimeter with two arguemnt. Now use the below logic…
Q: The kinetic energy of a moving object is given by the formula KE = ½mv2 where m is the object’s mass…
A: Program: mass = float(input("Enter the object's mass: ")) velocity = float(input("Enter the object's…
Q: 10) The assignment statement p = d; is legal even though p is not a Dog.
A: Please see the next step for solution
Q: Machine Problem:(Computing Body Mass Index)Body Mass Index (BMI) is a measure of health on weight.…
A: Your python program is given below as you required with an output.
Q: The phrase “divide and conquer” means that all of the programmers on a team should be divided and…
A: Gievn: The phrase “divide and conquer” means that all of the programmers on a team shouldbe divided…
Q: Write a program in which the Nibble Monster keeps asking for nibbles until the user enters 'Q' or…
A: NOTE : Since programming language is not mentioned. Therefore answering question in python language.…
Q: Q2/ Design a program with Writing a programming code using the Visual Basic language to calculate an…
A: Step 1 : Start Step 2 : In the Main module, Declaring the variables to hold the sales profit of the…
Q: An argument is expressed in English below. Sara is not excited. If Sara is not excited, then Sara…
A: Ans.) Sara is not excited == ~q If sara is not excited, than she will go to party== ~q --> r…
Q: What is the benefit of being able to define an initial value when you can assign a value to a…
A: Introduction: Variables hold data like numbers and words, whereas operators are symbols that execute…
Q: Based on this program, write a flow charts. Addendum: allow user input. */ // set up…
A: - We need to highlight the flow chart on the basis of the code provided.
Q: In a chemistry class there are ten students and each the students has taken 5 tests.The total mark…
A: #include <iostream>using namespace std;/* Student class*/class Student{ public:…
Q: Code a game of sudoku in C++ where the user needs to guess the missing numbers in the grid. The grid…
A: The code implementation is given in the below steps.
Q: QtAnswer the following (you are free to (assign the variables) sqrt(x)+abs(-20) S=…
A: let x=9 y= 5.5
Q: Problem You have code that needs to perform simple time conversions, like days to seconds, hours to…
A: To perform conversions and arithmetic involving different units of time, use the datetime module.…
Q: Python code for this scenario: There is a line of tourist trying to book a room for their vacation.…
A: Algorithm: Start Display menu to the user Ask user to enter number of guests 'n' Ask user to enter…
Q: In this lab, you use the flowchart and pseudocode found in the figure below to add code to a…
A: Required Java code is provided below :
Q: One type of investment is where you make a single deposit (called the principal) and then let…
A: Open visual studio. Select File -> New -> Project. Select Visual C++ -> Console App. Type…
Q: Write a program that asks the user for the number of males and the number of females registered in a…
A: Note : Since it is not mentioned which programming language to use so, i preferred to use Python…
Q: 1- Define a variable to hold student name, ex: "john smith" 2- For each letter in your name print…
A: CODE : public class Count { public static void main(String[] args) {…
Q: // This program gets student names continuously until XXX is entered. Then, for each student, quiz…
A: All the return boxes should be connected under one box.
Q: This example creates a program to teach a first grade child how to learn subtractions. The program…
A: Code Screenshot, output and code is below:
Q: Program Unit Score Calculator Console App Write a Python Console Application program that allows…
A: First, we will input all the marks. Then we will find the total marks by doing the summation of all…
Q: One type of investment is where you make a single deposit (called the principal) and then let…
A: Note: since programming language is not mentioned we are providing solution in python programming…
Q: import time import random name = input("Hello, what is your name? ") time.sleep(2) print("Nice to…
A: It is defined as a general-purpose, high-level, simple but effective object-oriented programming…
Q: Create a grade calculator that computes for the semestral grade of a course. Students could type…
A: Python Code: # Enter the name, course, Prelim, mid term and finalName = input("Enter Student Name:…
Q: Ask for a birthday, a favorite gift, and their dream job is and display that information fromated…
A: - We have to format the strings that we take input from the user and display it. - We are using C++…
Q: Suppose that overSpeed and fine are double variables. Assign the value to fine as follows: If 0 15,…
A: Explanation: The given scenario is achieved through “if-else-if” statement. Here, the two variables…
Python
Step by step
Solved in 2 steps
- Please do this in Python Programming and provide Screenshots The output should be exact same like in the examples. If the output in the example is in 2 decimals, then it should be like that. 1c - Othello 1 Othello, is a 2-player deterministic (no use of dice), perfect information (no information only known to one of the players) board game, similar to chess or go. The goal of this assignment is to give some information about the outcome once an Othello game has finished. This information is obtained by two measurements: The percentage of black pieces of all the pieces on the board. The percentage of the board that is covered in black pieces. The Othello board measures eight squares by eight squares, making the total number of squares sixty-four. Write a program that takes the number of white pieces followed by the number of black pieces as input. Print the two percentages as output. Enter the number of white pieces on the board: 34Enter the number of black pieces on the board:…Write an application that allows you to enter nine(and only nine, no more no less) integers and displays the values, their mean, and their median. (Java)Consider the following piece of code. animals = {'a': "ant", 'b': "baboon", 'c': "cat"} animals['d'] = "donkey" What will be printed if we execute the following print statement? print(animals) Question 9 options: {'d': "donkey"} {'a': "ant", 'b': "baboon", 'c': "cat"} {'a': "ant", 'b': "baboon", 'c': "cat", 'd': "donkey"} {'a': "ant", 'b': "baboon", 'c': "cat", 'd': "dog"}
- What is the data type of x after the following assignment: x = 2.0 + 3 - 4 * 12 string int floatWhat is the probability that in a classroom of x people, at least 2 will be born on the same day of the year (ignore leap year)? Use a Monte Carlo Simulation and a frequency table to write a program that calculates this probability, where the number of people (x) in the simulated class is given by the user. The probability for a class of size 23, should be right around 50%. PLEASE use the code outline given below to answer this question: import mathimport random # create and initialize frequency table:ft = []k = 0while(k < 365) : ft.append(0) k = k+1 # Allow the user to determine class size:print("Please type in how many people are in the class: ")x= int(input()) success = 0 # Simulate:c = 0while(c < 10000) : # Step 1: re-initialize birthday frequency table (it must be re-initialized for each play-through (why?): k = 0 while(k < 365) : ft[k] = 0 k = k+1 # Step 2: randomly get x birthdays and update frequency table: k = 0 while(k < x): # your code…Question: (Code must be in java language) Assuming that you have the functions “drawPolygon(int[] x, int[] y, int n)” for drawing polygon, “drawRectangle(int x, int y, int width, int height)” for drawing rectangle and “drawCircle(int xc, intyc, int radius)” for drawing circle; draw the given shape. Where: R(300,250), T1(325,275), T2(475,275), T3(400,400), P1(285,250), P2(225,275), P3(200,450), P4(285, 300), Q1(515,250), Q2(575,275), Q3(600,450), Q4(515,300)//Look attached image here Note: No need to write the definition of the methods, there are no marks for definition. Only use method calls to create the shape as shown in Figure 1.
- Write an application that determines the value of the coins in a jarand prints the total in dollars and cents. Read integer values thatrepresent the number of quarters, dimes, nickels, and penniesJava - Programming Develop a letter-guessing game in this assignment.Requirements:1). When the game begins, generate a random letter between A and Z;2). Display a message "I have a secret letter (A to Z), can you guess what it is?";3). Read the user's answer;4). Compare the user's answer and the random secret letter generated;5). If the user answer is before the random secret letter in the alphabet, display "Incorrect. Trysomething later in the alphabet" and go to Step 2;6). If the user answer is after the random secret letter in the alphabet, display "Incorrect. Trysomething earlier in the alphabet." and go to Step 2;7). If the user answer is the same as the random secret letter, display "Well done. Want to playagain (y/n)?";8). Read the user's answer. If the answer is 'y', go to Step 1. If the answer is 'n', go to Step 9;9). Display "Thanks for playing the game. Goodbye!". The program stops.Run your program several times. Take screenshots. Submit your Java file with the screenshotsThe below expression is used to determine whether or not the given year is a leap year. Add the appropriate parenthesis to make the expression more readable (assuming that you have a junior developer in your development team who is still learning how to program in Java efficiently). What is the output of the Boolean variable "isLeapYear"? int year = 2020; boolean isLeapYear = year % 4 == 0 && year % 100 != 0 || year % 400 == 0;
- Write a whole program to ask the user for his/her name, age, and gpa, then print on the screen "Hello NAME!, you are AGE years old and your Grade Point Average is GPA.", where NAME, AGE, and GPA are replaced by the values that the user typed.User data should be stored in a struct variable of type userType, which has three components: name of type string, age of type int, and gpa of type double. Write a program that reads students’ names followed by their test scores. The program should output each student’s name followed by the test scores and the relevant grade. It should also find and print the highest test score and the name of the students having the highest test score. Student data should be stored in a struct variable of type studentType, which has four components: studentFName and studentLName of type string, testScore of type int (testScore is between 0 and 100), and grade of type char. Suppose that the class has 20 students. Use an array of 20 components of type studentType.…Python programming In a department store sale, customers who purchase over 2000 are given 10% discount. Write a program that will accept for the purchase amount of a customer, solve for his/her discount if there’s any, ask for the money he/she is going to pay, then output the discounted price and the change of the customer.”Write a Java program to read the monthly salary amount of the employee and then print the category by using the following rules. Use the print the category. Rules on montly salary category salary>1000 GardeA 800<salary<=1000 Grade B 500<salary<=800 GradeC 300<salary<500 Grade D 150<salary<=300 Grade E otherwise Grade F