Answer:
import java.util.Scanner;
public class TestScores {
public static void main(String[] args) {
// create a 2D array of doubles to hold the test scores
double[][] scores = new double[5][3];
// use a Scanner to get input from the user
Scanner input = new Scanner(System.in);
// loop through each student and each test to get the scores
for (int i = 0; i < 5; i++) {
for (int j = 0; j < 3; j++) {
System.out.print("Enter score for student " + (i+1) + " on test " + (j+1) + ": ");
scores[i][j] = input.nextDouble();
}
}
// calculate the average score for each student and print it out
for (int i = 0; i < 5; i++) {
double totalScore = 0;
for (int j = 0; j < 3; j++) {
totalScore += scores[i][j];
}
double averageScore = totalScore / 3;
System.out.println("Average score for student " + (i+1) + ": " + averageScore);
}
// calculate the average score for each test and print it out
for (int j = 0; j < 3; j++) {
double totalScore = 0;
for (int i = 0; i < 5; i++) {
totalScore += scores[i][j];
}
double averageScore = totalScore / 5;
System.out.println("Average score for test " + (j+1) + ": " + averageScore);
}
}
}
Explanation:
Here's how the program works:
It creates a 2D array of doubles with 5 rows (one for each student) and 3 columns (one for each test).
It uses a Scanner to get input from the user for each test score for each student. It prompts the user with the student number and test number for each score.
It loops through each student and calculates the average score for each student by adding up all the test scores for that student and dividing by 3 (the number of tests).
It prints out the average score for each student.
It loops through each test and calculates the average score for each test by adding up all the test scores for that test and dividing by 5 (the number of students).
It prints out the average score for each test.
Note that this program assumes that the user will input valid numbers for the test scores. If the user inputs non-numeric data or numbers outside the expected range, the program will throw an exception. To handle this, you could add input validation code to ensure that the user inputs valid data.
which of the following correctly declares an array:
Choose one answer .
a. int array
b.array(10);
c.int array(10);
d.array array(10);
Answer:
a.
Explanation:
The option that correctly declares an array is int array.
What is an array?This is a term that connote a regular system or arrangement. Here, numbers or letters are said to be arranged in rows and columns.
In computing, An array is a term that describe memory locations box having the same name. All data in an array is said to be of the same data type.
Learn more about array from
https://brainly.com/question/26104158
What is the purpose of a host operating system?
It allows one guest to access software at a time.
It controls who can access software.
It stands between the guest OS and the hardware.
It is used to monitor network traffic.
Answer:
It controls who can access software.
Explanation:
compared with data, two disadvantages of data are that it is usually far more time consuming and more expensive to collect.
The fact that original data can be gathered from any demographic makes it appropriate for studies involving a variety of populations. Primary data can be expensive and time-consuming to gather, which is one drawback.
What drawbacks do open data have?
Open data has drawbacks, including the potential for prejudice, accidental privacy violations, misinterpretation and exploitation, decision-making based on low-quality data, and unclear accountability.
What are an example and a disadvantage?
benefit or equality being denied or lacking. the condition or occurrence of being in an unpleasant situation or circumstance: to be disadvantageous. His short temper is a disadvantage. something that puts one in an undesirable situation or state.
To know more about Disadvantages of data visit;
https://brainly.com/question/1596643
#SPJ4
Write a program that prompts the user to enter a decimal number between 0 and 15 and displays its corresponding binary value. Here are sample runs: Enter a decimal number between 0 and 15: 11 The binary number for 11 is 1011
Answer:
Attached is the program and the output
Explanation:
A program that prompts the user to enter a decimal number between 0 and 15 and displays its corresponding binary value and output
What's the latest tech
Answer:
1. Artificial Intelligence and Machine Learning
2. Data Science
3. Full Stack Development
4. Robotic Process Automation
5. Edge Computing
6. Virtual Reality and Augmented Reality
7. Blockchain
8. 5G
9. Cyber Security
10. Quantum Computing
11. Internet of Things
12. Big Data Analytics
13. Human Augmentation
14. Everything-as-a-Service(XaaS)
15. DevSecOps
16. Predictive & Personalised Medicine
17. Voice Search Technology
18. Drones and Unmanned Vehicles
19. Mass personalization and Micro-Moments.
20. Genomics and Gene Editing
Answer:
artificial intelligence
what are pixels?
A: The colors In an image
B: The overall size of the image
C: The overall file size of the image
D: The smallest unit on the image that can be controlled
Answer:
D: The smallest unit on the image that can be controlled
A processor operates at a clock rate of 1.6 GHz yet has a varying CPI for different instruction types. A given program has 400 ALU instructions which take the processor 7 cycles complete each instruction. It has 300 memory instructions that take 12 cycles to cycles to complete each instruction. It also has 90 branching operations that take 21 cycles to cycles to complete each instruction. How long does it take to execute this program
Answer:
0.0051825 ms
Explanation:
From the given information:
The clock time is = \(\dfrac{1}{clok \ rate}\)
\(=\dfrac{1}{6} Ghz\)
\(=\dfrac{1}{6}\times 10^9\)
To milliseconds, we have;
= 0.000000625 ms
However, the execution time is the sum total of all instruction types multiplied by the ratio of cycles taken per instruction and cycle time.
Mathematically;
Execution time is: \(\Bigg[Sum \ of \ all \Big(instruction \ type \times \dfrac{cycles taken }{instruction} \Big) \Bigg] \times cycle \ time\)
Recall that:
the cycles taken according to the ALU = 400 × 7 =2800
cycles required according to the memory instructions = 300 × 12 = 3600
cycles for branching = 90×21 = 1890
THUS;
Total cycles = 2800 + 3600 + 1890
= 8290 cycles
Finally, execution time = 8290 cycles × 0.000000625 ms
= 0.0051825 ms
How to code for a database?
Answer: How to code for a database? A database is an organized collection of data, generally stored and accessed electronically from a computer system. Where databases are more complex they are often developed using formal design and modeling techniques.
WWW. Wikipedia.com
Explanation: When creating a database first you need to make a software program then you need to start planing on what to do ...
{ A database management program (DBMS) is a software package design designed to manipulate, define, retrieve, and manage data in database.
A DBMS generally manipulates the data itself, the the data format, field names, record structure and file structure.}
HoPe ThIs HeLpS YoU!!
You enjoy helping people find solutions to problems that they are having with technology. Which job might be best for you?
A database manager
B technical support
C website design
D data scientist
Answer: B - technical support
Explanation:
What missing condition will give you the output shown? numB = 2 while _____: numB = numB + 3 print(numB) Output: 14 numB 10 numB > 12 numB < 10
Answer:
A. numB < 12
Explanation:
Correct answer edge 2020
Answer: A. numB < 12
Explanation: got it right edgen
There is a surplus of scientific researchers for a vaccine. This means the demand for this career has
decreased
decreased then increased
increased
stayed the same
Create a Raptor program to store a list of customer names and phone numbers entered by the user to a text file. Save your text file as “Customers.txt”.
Answer:
b
Explanation:
PLEASE HELP I REALLY NEED IT ASAP
Select the correct answer. Layla and her team have installed a fire alarm system in an office. The alarm system connects to a wireless network, so it can be monitored using smartphones and computers connected to the same network. Which wireless technology does the fire alarm system use?
OA satellite
OB. Bluetooth
O C. infrared
OD. WI-FI
Answer:
wifi
Explanation:
if it's running on the same network that's wifi
Answer:
The correct answer is D. Wi-Fi.
Explanation:
I got it right on the Edmentum test.
What are the 5 types of scanning?
The 5 types of scanning :
Flatbed Scanners.Sheetfed Scanners.Handheld Scanner. Drum Scanner. Photo Scanner.What is scanning ?To scan a text is to skim through it rapidly in search of a particular piece of information. Scanning is frequently employed in daily life, such as when searching up a term in a dictionary or locating a friend's name in your phone's contacts list.There are essentially three forms of scanning. These include vulnerability scanning, port scanning, and network scanning.Drum scanners, flatbed scanners, and handheld scanners are the three types of scanners that are available. Drum scanners are usually utilised in the publishing business to print high-quality photos, whereas flatbed scanners are typically found in workplaces and schools.The fundamental scanning procedure consists of three steps: scan, register, and detail.Learn more about scanning refer to :
https://brainly.com/question/24937533
#SPJ4
Proper numeric keyboarding technique includes all of these techniques except
O keeping your wrist straight
O resting your fingers gently on the home keys
O looking at the keys
O pressing the keys squarely in the center
Answer: Its the 1st choice, 2nd choice, and the final one is the 4th one. (NOT the third answer choice)
Explanation: (I just took the test)... Hopefully this helps and good luck.
Which of the following tools would you use to simulate a large number of client connections to a website, test file downloads for an FTP site, or simulate large volumes of email?
In order to simulate a large number of client connections to a website, test file downloads for an FTP site, or simulate large volumes of email, one can use a load tester.
How to explain the informationA load testing tool is software that enables the simulation of virtual users or clients, which can generate high volumes of traffic to a system or application under test.
Load testing tools help to identify the system's behavior under different types of loads and help to determine the system's performance, scalability, and reliability.
There are several load testing tools available in the market, such as Apache JMeter, LoadRunner, Gatling, Locust, and many more.
Learn more about website on
https://brainly.com/question/32178393
#SPJ1
b. Some of Company X's new practices and systems are unethical. Business ethics is a set of codes
about how a business should conduct itself. In what ways is Company X not applying ethical practices?
(1 point)
Answer:
They are changing schedules without proper notice, cutting workers without proper notice and falsely advertising.
Explanation:
Write a program that tells what coins to give out for any amount of change from 1 cent to 99 cents. For example, if the amount is 86 cents, the output would be something like the following:
86 cents can be given as 3 quarters 1 dime and 1 penny
Use coin denominations of 25 cents (quarters), 10 cents (dimes), and 1 cent (pennies). Do not use nickel and half dollar coins. Your program will use the following function (among others):
void computeCoin(int coinValue, int& number, int& amountLeft);
For example, suppose the value of the variable amountleft is 86. Then, after the following call, the value of number will be 3 and the value of amountLeft will be 11 (because if oyu take three quarters from 86cents, that leaves 11 cents):
computecoins (25, number, amountLeft);
Include a loop that lets the user repeat this computation for new input values until the suer says he or she wants to end the program (Hint: use integer division and the % operator to implement this function.)
Add all numbers up
and you will get your sum
I need help with the following c program:
(1) Prompt the user for a string that contains two strings separated by a comma. (1 pt)
Examples of strings that can be accepted:
Jill, Allen
Jill , Allen
Jill,Allen
Ex:
Enter input string:
Jill, Allen
(2) Report an error if the input string does not contain a comma. Continue to prompt until a valid string is entered. Note: If the input contains a comma, then assume that the input also contains two strings. (2 pts)
Ex:
Enter input string:
Jill Allen
Error: No comma in string.
Enter input string:
Jill, Allen
(3) Extract the two words from the input string and remove any spaces. Store the strings in two separate variables and output the strings. (2 pts)
Ex:
Enter input string:
Jill, Allen
First word: Jill
Second word: Allen
(4) Using a loop, extend the program to handle multiple lines of input. Continue until the user enters q to quit. (2 pts)
Ex:
Enter input string:
Jill, Allen
First word: Jill
Second word: Allen
Enter input string:
Golden , Monkey
First word: Golden
Second word: Monkey
Enter input string:
Washington,DC
First word: Washington
Second word: DC
Enter input string:
q
Answer: ↓NEW↓
#include <stdio.h>
#include <string.h>
int main() {
char input[100];
char first[50];
int i, len;
while (1) {
printf("Enter input string:\n");
fgets(input, 100, stdin);
len = strlen(input);
if (len > 0 && input[len-1] == '\n') {
input[len-1] = '\0';
}
if (strcmp(input, "q") == 0) {
break;
}
int found_comma = 0;
for (i = 0; i < len; i++) {
if (input[i] == ',') {
found_comma = 1;
break;
}
}
if (!found_comma) {
printf("Error: No comma in string.\n");
continue;
}
int j = 0;
for (i = 0; i < len; i++) {
if (input[i] == ' ') {
continue;
}
if (input[i] == ',') {
first[j] = '\0';
break;
}
if (j < 50) {
if (input[i] >= 'A' && input[i] <= 'Z') {
first[j] = input[i] - 'A' + 'a';
} else {
first[j] = input[i];
}
j++;
}
}
printf("First word: %s\n", first);
}
return 0;
}
Explanation:
↓OLD↓
#include <stdio.h>
#include <string.h>
int main() {
char input[100];
char first[50], second[50];
int i, len;
while (1) {
printf("Enter input string:\n");
fgets(input, 100, stdin);
len = strlen(input);
if (len > 0 && input[len-1] == '\n') { // remove newline character
input[len-1] = '\0';
}
if (strcmp(input, "q") == 0) { // check if user wants to quit
break;
}
// check if input contains a comma
int found_comma = 0;
for (i = 0; i < len; i++) {
if (input[i] == ',') {
found_comma = 1;
break;
}
}
if (!found_comma) { // report error if no comma is found
printf("Error: No comma in string.\n");
continue;
}
// extract first and second words and remove spaces
int j = 0;
for (i = 0; i < len; i++) {
if (input[i] == ' ') {
continue;
}
if (input[i] == ',') {
first[j] = '\0';
j = 0;
continue;
}
if (j < 50) {
if (input[i] >= 'A' && input[i] <= 'Z') { // convert to lowercase
first[j] = input[i] - 'A' + 'a';
} else {
first[j] = input[i];
}
j++;
}
}
second[j] = '\0';
j = 0;
for (i = 0; i < len; i++) {
if (input[i] == ' ') {
continue;
}
if (input[i] == ',') {
j = 0;
continue;
}
if (j < 50) {
if (input[i] >= 'A' && input[i] <= 'Z') { // convert to lowercase
second[j] = input[i] - 'A' + 'a';
} else {
second[j] = input[i];
}
j++;
}
}
second[j] = '\0';
printf("First word: %s\n", first);
printf("Second word: %s\n", second);
}
return 0;
}
This program prompts the user for a string that contains two words separated by a comma, and then extracts and removes any spaces from the two words. It uses a loop to handle multiple lines of input, and exits when the user enters "q". Note that the program converts all uppercase letters to lowercase.
You are given an array of integers, each with an unknown number of digits. You are also told the total number of digits of all the integers in the array is n. Provide an algorithm that will sort the array in O(n) time no matter how the digits are distributed among the elements in the array. (e.g. there might be one element with n digits, or n/2 elements with 2 digits, or the elements might be of all different lengths, etc. Be sure to justify in detail the run time of your algorithm.
Answer:
Explanation:
Since all of the items in the array would be integers sorting them would not be a problem regardless of the difference in integers. O(n) time would be impossible unless the array is already sorted, otherwise, the best runtime we can hope for would be such a method like the one below with a runtime of O(n^2)
static void sortingMethod(int arr[], int n)
{
int x, y, temp;
boolean swapped;
for (x = 0; x < n - 1; x++)
{
swapped = false;
for (y = 0; y < n - x - 1; y++)
{
if (arr[y] > arr[y + 1])
{
temp = arr[y];
arr[y] = arr[y + 1];
arr[y + 1] = temp;
swapped = true;
}
}
if (swapped == false)
break;
}
}
What are the purposes of a good web page design? The purpose of a good web page design is to make it and .
Answer:
responsiveness and intuitive
Explanation:
The two main purposes of a good web page design is responsiveness and intuitive. A webpage needs to be designed in such a way that the individual using it can easily find what they are looking for and understand what each function in the webpage does without having to ask for help or go through an extensive tutorial. They need to be able to use the website for the first time and immediately be able to use it as if they have used it countless times before. The webpage also needs to be designed with responsiveness in mind. So much so that the webpage runs fluently, loads images fast, and scales to the size of the monitor correctly. As a rule the webpage should not take longer than 2 seconds to load.
Write a python program to find the volume of the pepsi present in the can which is in the shape of cylinder accepting the radius and height of the can from user.(Note :Apply float input and display Radius ,Height, Volume of Pepsi in can)
(V = pi r^2 h )
Answer:
r=float(input("Enter radius: "))
h=float(input("Enter height: "))
v=3.14*r**2*h
print(r)
print(h)
print(v)
This is the answer, hope it helped!
Which of the following statements converts a String object named subtotalString to a double variable named subtotal?a.double subtotal = Double.toString(subtotalString);b.double subtotal = subtotalString.parseDouble;c.double subtotal = Double.parseDouble(subtotalString);d.double subtotal = (double) subtotalString
Answer:
double subtotal = Double.parseDouble(subtotalString);
Explanation:
Required
Determine which method converts string object to double variable
From the question;
The string object is: subtotalString
The double variable is: subtotal
From the given options (a) to (d), the option that answers the question is:
double subtotal = Double.parseDouble(subtotalString);
And it follows the syntax:
[datatype] [variable-name] = [Data-type].parse[Datatype]([string-variable])
Make me a full RPG game in python 1, reward is BIG
Role-playing games (sometimes known as role-playing games, Players take on the roles of characters in a fictional world in role-playing games .
Thus, Players assume responsibility for carrying out these roles in a story, either through actual acting or through a process of deliberate character development decisions.
Many games include a formal set of rules and regulations that determine whether certain actions are successful or unsuccessful.
Role-playing video games come in a variety of formats. In the original form, often known as the tabletop role-playing game (TRPG or TTRPG), players converse while acting out their characters' actions in live action role-playing (LARP).
Thus, Role-playing games (sometimes known as role-playing games, Players take on the roles of characters in a fictional world in role-playing games .
Learn more about Fictional world, refer to the link:
https://brainly.com/question/2516102
#SPJ1
What is the action take to the input called?
Answer:
Control types created with INPUT; Examples of forms containing INPUT controls ... The scope of the name attribute for a control within a FORM element is the FORM element. ... Applications should use the id attribute to identify elements. ... The program that will handle the completed and submitted form (the action attribute).
Explanation:
numDistance is read from input as the size of the vector. Then, numDistance elements are read from input into the vector bikingNumbers. Use a loop to access each element in the vector and if the element is an odd number, output the element followed by a newline.
Ex: If the input is 4 128 173 129 47, then the output is:
173
129
47
The distance between and is the difference between the two numbers.
Thus, Since the distance is a positive quantity, we want to subtract a small number from a big number to get a positive result. However, sometimes we don't know which of the two numbers is bigger.
If the number line above wasn't given, we wouldn't know is greater than. To get a positive result every time, we take the absolute value of the difference.
The number line serves as the primary visual representation in statistics, it is common practice to compare two points on the number line and calculate their distance from one another.
Thus, The distance between and is the difference between the two numbers.
Learn more about Number distance, refer to the link:
https://brainly.com/question/19946572
#SPJ1
application of computer in insurance
Answer:
To keep a list of insured members in the offices.
Explanation:
Compunters can be used to keep records of insured individual and their details
What kinds of
programs are included in system software?
Answer:
Programs such as the operating system, database management systems, networking software, translators, and software utilities.
Explanation: Hope it helps you :))))
Have a good day.
Choose the word that matches each definition. A(n) is a statement that assigns a value to a variable.
An assignment statement is a statement that assigns a value to a variable.
What is a variable?A variable can be defined as a specific name which refers to a location in computer memory and it is typically used for storing a value such as an integer.
This ultimately implies that, a variable refers to a named location that is used to store data in the memory of a computer. Also, it is helpful to think of variables as a storage container which holds data that can be changed in the future.
The methods for passing variables.In Computer technology, there are two main methods for passing variables to functions and these include the following:
Pass-by-value.Pass-by-reference.In conclusion, an assignment statement refers to a type of statement which s typically used by computer programmers and software developers to assign a value to a variable.
Read more on assignment statement here: https://brainly.com/question/25875756
#SPJ1
Characteristics of VR headsets