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
zavuch27 [327]
2 years ago
12

Given a number n, for each integer i in the range from 1 to n inclusive, print one value per line as follows:

Computers and Technology
1 answer:
monitta2 years ago
3 0

The program is an illustration of loops and conditional statements

<h3>Loops</h3>

Loops are used to perform repetitive operations

<h3>Conditional statements</h3>

Conditional statements are statements that are used to make decisions, depending on their truth values

<h3>Python program</h3>

The program written in Python where comments are used to explain each line is as follows:

#This gets input for n

n = int(input())

#This iterates through n

for i in range(1,n+1):

   #If the current number is not a multiple of 3 and 5

   if not(i%3 == 0 or i%5==0):

       #This prints the number

       print(i,end="")

   else:

       #This prints "Fizz", if the current number is a multiple of 3

       if i%3 == 0:

           print("Fizz",end="")

       #This prints "Buzz", if the current number is a multiple of 5

       if i%5==0:

           print("Buzz",end="")

   #This prints a new line

   print()

Read more about loops and conditional statements at:

brainly.com/question/26098908

You might be interested in
Need help asap<br> give the correct answer!!
blagie [28]
It’s either b or c, but my final answer would be C
4 0
2 years ago
Read 2 more answers
_______ allows you to add formatting such as shapes and colors to text. a. worddraw b. wordart c. worddesign d. wordshapes
4vir4ik [10]
Word Design is the answer.
4 0
3 years ago
Read 2 more answers
Which of the following do you need to remeber about true/false questions?
lina2011 [118]
All parts of a statement must be true for it to be true
7 0
3 years ago
Which step is first in changing the proofing language of an entire document?
Genrish500 [490]
Select the whole document by pressing Ctrl+a.
7 0
3 years ago
What is the quickest way to remove all filters that have been applied to a worksheet?
RSB [31]

Answer:

Select the worksheet and click Delete All Filters.

Explanation:

5 0
3 years ago
Read 2 more answers
Other questions:
  • What does the machine do and how do the operators react to their work?
    13·1 answer
  • What are the Database used in RDBMS and DBMS<br>please answer immediately​
    10·1 answer
  • How does a firewall provide network security
    8·1 answer
  • Does any one play sniper clash 3d ??? ​
    9·2 answers
  • What is the encryption cipher that was the precursor to des??
    5·1 answer
  • How will you apply what you have learned in our topic today in a real life situation? Show your answers in the acronyms provided
    6·1 answer
  • What should be a technicians first step in an A/C system
    7·1 answer
  • Please help!! I need this asap! thank you so much!! &lt;3
    6·1 answer
  • Advantages and disadvantages of java
    10·1 answer
  • What is a zerø-day exploit? No go.ogle &gt;:(
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!