Answer to Question #246014 in Algorithms for jess

Question #246014

given a set of 15 integer numbers that includes both positive and negative values.draw and write an algorithm that will read in the values including zero and the numbers of negative values found in the set. print out yhe counted values


1
Expert's answer
2021-10-03T11:45:52-0400


1 Set counter = 0
2 Set i = 0
3 Read ith number x_i
4 If x_i < 0 Then add 1 to conter
5 Add 1 to i
6 If i < 15 goto step 3
7 Print counter

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS