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
sesenic [268]
3 years ago
12

Write code that prints: Ready! firstNumber ... 2 1 Run!

Computers and Technology
1 answer:
motikmotik3 years ago
3 0

Answer:

The program to this question can be defined as follows:

Program:

num=int(input("Enter any number: ")) #defining variable num, that take value from user

val=0; #defining variable val

for i in range(num): #defining loop to calculate value in decreasing order

   val=num-i; #holding value in variable

   print(val) #print value

Output:

Enter any number: 3

3

2

1

Explanation:

In the above-given code, a variable "num" is declared, that uses input function to take value from the user end, in the next line a "val" variable is defined, that calculates values and print it in decreasing order.

  • In the next step, a for loop is declared, inside the loop a "val" variable uses num and loop variable "i" to calculate the value in decreasing order.
  • In the last print method is used that prints "val" variable value.
You might be interested in
What do you think is the most effective way to ensure that code adheres to good coding standards? (1 correct answer)
Stella [2.4K]

Answer:

The code should pass all the unit test cases.

Explanation:

Unit testing is an important step in the development process, because if done correctly, it can help detect early flaws in code which may be more difficult to find in later testing stages.

When there is a development of a software, at that moment there are many small programs, which are developed by coders and, after they are created, those programs are attached together to make a full working system.

The correct option is the code should pass all the unit test cases....

7 0
3 years ago
Read 2 more answers
What is the outlined area called?
Yakvenalex [24]

Answer:

Ribbon

Explanation:

I would want to believe that this question is asking us about the outlined area in the image attached below. The ribbon consists of the main tabs you see when you open up your Word document by default. They include the home, insert, page layout, in that order, all the way upto the view tab. The main tabs are split into groups and these groups are further split into command options that help users complete a task. If you want to, you can minimize the ribbon and remain with the tab names only by hitting CTRL + F1

5 0
4 years ago
Arrange these steps of creating a presentation in the correct order.
koban [17]

1. Click Create Presentation

2. Background

3. Wizard

4. Animation

7 0
4 years ago
Read 2 more answers
Write the code for the method getNewBox. The method getNewBox will return a GiftBox that has dimensions that are m times the dim
liraira [26]

Answer:

public class GiftBox{

private int length;

private int width;

private int height;

 

public GiftBox(double length, double width, double height) {

this.length = length;

this.width = width;

this.height = height;

}

 

public static GiftBox getNewBox(GiftBox giftBox, double m) {

return new GiftBox(m * giftBox.length, m * giftBox.width, m * giftBox.height);

}

 

private boolean fitsInside(GiftBox giftBox) {

if(giftBox.length < this.length && giftBox.width <this.width

&& giftBox.height < this.height) {

return true;

}

return false;

}

 

public static void main(String []args){

GiftBox giftBox = new GiftBox(3.0 , 4.0, 5.0);

GiftBox newGiftBox = getNewBox(giftBox, 0.5);

System.out.println("New Box length: " + newGiftBox.length);

System.out.println("New Box width: " + newGiftBox.width);

System.out.println("New Box height: " + newGiftBox.height);

 

GiftBox gift = new GiftBox(3.0 , 4.0, 5.0);

GiftBox other = new GiftBox(2.1 , 3.2, 4.3);

GiftBox yetAnother = new GiftBox(2.0 , 5.0, 4.0);

 

System.out.println(gift.fitsInside(other));

System.out.println(gift.fitsInside(yetAnother));

}

}

Explanation:

The getNewBox is a public method in the GiftBox class in the Java source code above. It returns the GiftBox object instance increasing or multiplying the dimensions by the value of m of type double.

3 0
3 years ago
When you move into a new home or apartment, the first thing on your checklist should be to have the ____________ changed. (5 Let
Lynna [10]

Answer:

When you move into a new home or apartment, the first thing on your checklist should be to have the <u>locks</u> changed

Explanation:

Changing the locks

Given that the way the previous owners of the new home or apartment made use of the locks and the keys are usually not completely known to the new owners, one may never know all those that have a key or a means to gain access into the apartment or home. Therefore, in order to guarantee proper security, it is a good practice to have as one of the first thing on the checklist, the changing of the locks of the entrance doors and windows of the new home or apartment.

5 0
3 years ago
Other questions:
  • Which education level has the highest return on investment (ROI)? AHigh School Diploma BROI is equal for all of the above. CSeni
    6·1 answer
  • When configuring services, what linux directory typically contains server configuration files?
    8·1 answer
  • Sukhi needs to insert a container into her form to collect a particular type of information. Which object should she insert?
    6·1 answer
  • What should you do before using a website to store student information ? A. Read and understand the website’s privacy contract
    11·2 answers
  • Please help it a timed test
    10·2 answers
  • 2.Explain the differences between kernel applications of the OS and the applications installed by an organization or user.
    10·1 answer
  • Trading stock or selling stock, selling real estate for profit, and selling other assets that gain value over time.
    13·1 answer
  • Nobody mind this plz
    14·1 answer
  • The National Vulnerability Database (NVD) is responsible for actively performing vulnerability testing for every company's softw
    8·1 answer
  • Write a paragraph discussing privacy issues on the internet<br> and their impact on human lives.
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!