× Didn't find what you were looking for? Ask a question
Top Posters
Since Sunday
a
5
k
5
c
5
B
5
l
5
C
4
s
4
a
4
t
4
i
4
r
4
r
4
New Topic  
ian18 ian18
wrote...
Posts: 223
Rep: 0 0
5 years ago
Which is the correct way to load an array named WorkHours with the number of hours that five employees worked last week?

a.   Declare WorkHours[5] As Float
Declare J As Integer
For (J = 0; J <= 4; J++)
    Write “Input number hours worked for employee” + J + 1
    Input WorkHours[J]
End For
b.   Declare WorkHours[4] As Float
Declare J As Integer
For (J = 0; J <= 4; J++)
    Write “Input number hours worked for employee” + J + 1
    Input WorkHours[J + 1]
End For
c.   Declare WorkHours[5] As Float
Declare J As Integer
For (J = 0; J<=5; J++)
    Write “Input number hours worked for employee” + J
    Input WorkHours[J + 1]
End For
d.   None of these are correct
Textbook 
Prelude to Programming

Prelude to Programming


Edition: 6th
Authors:
Read 205 times
1 Reply
Replies
Answer verified by a subject expert
godinggoding
wrote...
Posts: 267
Rep: 5 0
5 years ago
Sign in or Sign up in seconds to unlock everything for free
More solutions for this book are available here
1

Related Topics

ian18 Author
wrote...

5 years ago
this is exactly what I needed
wrote...

Yesterday
Good timing, thanks!
wrote...

2 hours ago
Thanks
New Topic      
Explore
Post your homework questions and get free online help from our incredible volunteers
  976 People Browsing
Related Images
  
 190
  
 294
  
 172
Your Opinion
Who will win the 2024 president election?
Votes: 3
Closes: November 4

Previous poll results: What's your favorite coffee beverage?