1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Mila [183]
2 years ago
13

X = 9 % 2if (x == 1):  print ("ONE")else:  print ("TWO")

Computers and Technology
1 answer:
IgorC [24]2 years ago
4 0

Answer:

ONE

Explanation:

It prints one because % is modulus, which is remainder division. It divides the numbers provided and returns the remainder of the division. 9 / 2 = 4 with 1 remainder, which leads us to our answer.

You might be interested in
Write a program that asks the user to enter the amount that he or she has budgeted for a month. A loop should then prompt the us
Dominik [7]

Answer:

import java.util.*;

public class Main {

public static void main(String[] args)

{

Scanner scan = new Scanner();

double budget=0, num=0, total=0;

System.out.println("Your budget for the month? ");

budget=scan.nextDouble();

System.out.println("enter all expense, and after that type -9999 to quit: ");

while(num != -9999)

{

total+=num;

num=scan.nextDouble();

}

if(total<=budget)

{

System.out.println("under budget by ");

System.out.println(budget-total);

}

else

{

System.out.println("over budget by ");

System.out.println(total-budget);

}

}

}

Explanation:

  • Take the budget as an input from user and store it to the budget variable.
  • Loop until user has entered all his expenses and keep on adding them to the total variable.
  • Check If the total is less than or equal to budget or otherwise, and then print the relevant message accordingly.
4 0
3 years ago
a problem exists when the current condition differs from a desired condition. This idea defines which step in problem-solving?
zhannawk [14.2K]

In algorithm the idea defines a decision box

5 0
3 years ago
Read 2 more answers
When referring to computers, what does CRT stand for?
vampirchik [111]

CRT stands for <u>"Cathode Ray Tube".</u>

CRT are the many tiny green, blue, and red beams that shine to create an image on the computer screen.

8 0
3 years ago
85 points!!!!!!!!!!!!!!! is creating a résumé. Which parts of her résumé has she done correctly?
Ket [755]

Answer:

Decorative font, because having a fancy font on a resume is not going to be looked at

5 0
2 years ago
Write a program that accepts any number of homework scores ranging in value from 0 through 10. Prompt the user for a new value i
vazorg [7]

Answer:

This program is written in C++

Note that the average is calculated without the highest and the least value.

Comments are used for explanatory purpose

See attachment for .cpp file.

Program starts here

#include<iostream>

using namespace std;

int main()

{

int num;

cout<<"Enter Number of Test [0-10]: ";

//cin>>num;

while(!(cin>>num) || num > 10|| num<0)

{

cout << "That was invalid. Enter a valid digit: "<<endl;

cin.clear(); // reset the failed input

cin.ignore(123,'\n');//Discard previous input

}

//Declare scores

int scores[num];

//Accept Input

for(int i =0;i<num;i++)

{

cout<<"Enter Test Score "<<(i+1)<<": ";

cin>>scores[i];

}

           //Determine highest

           int max = scores[0];

           for (int i = 1; i < num; i++)

           {

               if (scores[i] > max)

               {

                   max = scores[i];

               }

           }

           //Determine Lowest

           int least = scores[0];

           for (int i = 1; i < num; i++)

           {

               if (scores[i] < least)

               {

                   least = scores[i];

               }

           }

           int sum = 0;

           //Calculate total

           for(int i =0; i< num;i++)

           {

               sum += scores[i];

           }

           //Subtract highest and least values

           sum = sum - least - max;

           //Calculate average

           double average = sum / (num - 2);

           //Print Average

           cout<<"Average = "<<average<<endl;

           //Print Highest

           cout<<"Highest = "<<max<<endl;

           //Print Lowest

           cout<<"Lowest = "<<least;

return 0;  

}

Download cpp
8 0
3 years ago
Other questions:
  • Which option will enable Mina to apply several formats to the spreadsheet cells at the same time?
    5·1 answer
  • You're an administrator for a large corporation and you are responsible for deploying computers often and quickly. What server d
    10·1 answer
  • 3.24 LAB: Seasons
    13·1 answer
  • Management of software development consist of?
    15·1 answer
  • The process of identifying and removing logical errors and runtime errors is called ..............
    5·2 answers
  • Write a program that allows the user to continuously input the value n until a negative number is entered
    10·1 answer
  • which term describes the layer of software that resides between the virtual operating system and the physical hardware it runs o
    5·1 answer
  • Goals of the project objectives
    6·1 answer
  • Another word for asking a question of your data is to _____ it.
    6·1 answer
  • What is the shortcut key to create a new desktop ​
    11·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!