Question

I need this in PSEUDOCODE please: Write a FOR loop (just the loop) to print out...

I need this in PSEUDOCODE please:

Write a FOR loop (just the loop) to print out the following sequence of numbers: 1, 4, 7, 10, 13, 16, 19, 22, 25

Homework Answers

Answer #1

SOLUTION:

Dear Student, I am writing a pseudocode for the given query. And i am also explaining the pseudocode with the comments for your understanding.

PSEUDOCODE:  

START  
SET A = 1 // Firstly we set A with 1
FOR I = 1 TO 9 // Start the loop i = 1 and go through till 9
DISPLAY: VALUE OF A // Now we print the value of A that is starting from 1
A = A + 3 (INCREMENT BY 3 IN A) // After that increment in A by 3 so it prints 1, 4, 7......so on
END FOR // And after that end of the for loop
STOP

OUTPUT:

1       4       7       10      13      16      19      22      25

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Uses a while loop to print the numbers from 3 - 19. Uses a do-while loop...
Uses a while loop to print the numbers from 3 - 19. Uses a do-while loop to print the numbers from 42 - 56. Uses a for loop to print the numbers from 87 - 95. Asks the user for 2 numbers. Uses a loop to print all numbers between the given numbers, inclusive. Note: Consider that your user's second number can be lower! (see example below) Note: Also consider that your user might give you two of the same...
I NEED THIS IN C++ PLEASE! In this lab the completed program should print the numbers...
I NEED THIS IN C++ PLEASE! In this lab the completed program should print the numbers 0 through 10, along with their values multiplied by 2 and by 10. You should accomplish this using a for loop instead of a counter-controlled while loop. Instructions: Write a for loop that uses the loop control variable to take on the values 0 through 10. In the body of the loop, multiply the value of the loop control variable by 2 and by...
write a Nested loop in C# to print out the following output using windows form. 0...
write a Nested loop in C# to print out the following output using windows form. 0 0 1 0 2 4 0 3 6 9 0 4 8 16 32
Write a program called factor.py that uses at least one loop to print out “Multiple of...
Write a program called factor.py that uses at least one loop to print out “Multiple of x!” for each element x that is a multiple of the factors: 5, 7, or 13 between zero and 100. If a number is a multiple of more than one factor, for example 35 is a multiple of both 5 and 7, print out “Multiple of 5 and 7!”. If all three are factors, then print out “Multiple of 5 and 7 and 13!”....
Using a for loop and range command, print the sequence of numbers from 1 to 20...
Using a for loop and range command, print the sequence of numbers from 1 to 20 (skipping two numbers for each element); that is, your code should print out the numbers 1,4, 7, 10, … (max should not exceed 20). Use x as the variable name
Write a for loop to print all elements in courseGrades, following each element with a space...
Write a for loop to print all elements in courseGrades, following each element with a space (including the last). Print forwards, then backwards. End each loop with a newline. Ex: If courseGrades = {7, 9, 11, 10}, print: 7 9 11 10 10 11 9 7 Hint: Use two for loops. Second loop starts with i = courseGrades.length - 1. (Notes) IN JAVA: import java.util.Scanner; public class CourseGradePrinter { public static void main (String [] args) { Scanner scnr =...
Please, write a loop to print even numbers of an array a with pointers. You can...
Please, write a loop to print even numbers of an array a with pointers. You can use a variable “size” for array size
IN C++ AS SIMPLE AS POSSIBLE ______ Re-write the given function, printSeriesSquareFifth,  to use a while loop...
IN C++ AS SIMPLE AS POSSIBLE ______ Re-write the given function, printSeriesSquareFifth,  to use a while loop (instead of for). • The function takes a single integer n as a parameter • The function prints a series between 1 and that parameter, and also prints its result • The result is calculated by summing the numbers between 1 and n (inclusive). If a number is divisible by 5, its square gets added to the result instead. • The function does not...
Given this pseudocode:   input: sequence of numbers ak k, length of sequence answer := a1 for...
Given this pseudocode:   input: sequence of numbers ak k, length of sequence answer := a1 for i = 2 to k if (ai > answer), then answer = ai End-for What is the value of answer for the sequence {-1, 4, -7, 10, 2} with k = 5? Please provide detailed answer! Thank you!
In Java programming language 11.Create the code for a for loop to print the numbers 1  through...
In Java programming language 11.Create the code for a for loop to print the numbers 1  through 5 inclusive vertically so the output is 1 2 3 4 5 11b What is the output of the following               OUTPUT int i=3; while(int i >0) { System.out.println(i); i--; } 11c What is the output of the following               OUTPUT for(int i=3;i<10;i++) System.out.println(3*i); 11d Create the line of code to print the numbers 10 through 1 decreasing by 1 each time 11e Create the line of code...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT