help!! i don't know how to get the same output. here's the source code in c language: #include // TODO: Declare the display() function here int main(void) { int world[100] = { 1,3,2,4,5,7,6,8,9,11, 100,13,0,14,16,17,3,18,20,10, 12,8,15,14,-5,17,19,18,1,9,5, 10,13,11,14,16,22,0,18,20,3, 99,13,15,14,22,17,19,0,23,2, 12,13,15,22,16,17,56,18,44,99, 2,13,22,14,16,89,19,69,101,34, 12,22,15,14,78,17,69,18,2,33, 4,13,77,7,10,17,19,91,4,22, 12,98,15,14,15,17,19,18,7 }; display(world, 100); return 0; } // TODO: Define the display() function here
help!! i don't know how to get the same output. here's the source code in c language: #include // TODO: Declare the display() function here int main(void) { int world[100] = { 1,3,2,4,5,7,6,8,9,11, 100,13,0,14,16,17,3,18,20,10, 12,8,15,14,-5,17,19,18,1,9,5, 10,13,11,14,16,22,0,18,20,3, 99,13,15,14,22,17,19,0,23,2, 12,13,15,22,16,17,56,18,44,99, 2,13,22,14,16,89,19,69,101,34, 12,22,15,14,78,17,69,18,2,33, 4,13,77,7,10,17,19,91,4,22, 12,98,15,14,15,17,19,18,7 }; display(world, 100); return 0; } // TODO: Define the display() function here
Chapter8: Advanced Method Concepts
Section: Chapter Questions
Problem 8RQ
Related questions
Question
help!! i don't know how to get the same output. here's the source code in c language:
#include<stdio.h>
// TODO: Declare the display() function here
int main(void) {
int world[100] = {
1,3,2,4,5,7,6,8,9,11,
100,13,0,14,16,17,3,18,20,10,
12,8,15,14,-5,17,19,18,1,9,5,
10,13,11,14,16,22,0,18,20,3,
99,13,15,14,22,17,19,0,23,2,
12,13,15,22,16,17,56,18,44,99,
2,13,22,14,16,89,19,69,101,34,
12,22,15,14,78,17,69,18,2,33,
4,13,77,7,10,17,19,91,4,22,
12,98,15,14,15,17,19,18,7
};
display(world, 100);
return 0;
}
// TODO: Define the display() function here
![main.c
1. Show me the world
1 #includestdio.h>
by CodeChum Admin
2
// TODO: Declare the display) function here
4
3
Hi Programmer, I'm planning to impress my crush. It seems that
she likes nerd stuff so what I'm planning to do is I want to show
her all of the world array I have.
6" int nain(void) {
int world[100] = {
1,3,2,4,5,7,6,8,9,11,
100,13,0,14,16,17,3,18, 20,10,
12,8,15,14,-5,17,19,18,1,9,5,
10,13,11,14,16 , 22,0,18, 20 ,3,
99,13,15 ,14,22,17,19 ,0, 23,2,
12, 13,15 ,22,16,17,56,18,44,99,
2,13,22,14,16 ,89,19,69, 101,34,
12, 22,15 ,14,78,17,69,18 ,2,33,
4,13,77,7,10,17,19 ,91,4,22,
12,98,15 ,14,15,17,19,18,7
Can you help me with this?
9
10
11
Instructions:
12
13
1. In the code editor, you are provided with the main() function
14
that declares an array with initial values and calls the
15
display() function.
16
2. This display() function hasn't been declared and defined yet.
17
18
This is your task. The details of this function are:
19
1. Return type - void
display (world, 100);
20
2. Name - display
21
3. Parameters
22
return 0;
23 }
1. int* - an array
24
2. int - the size of an array
25 / TODO: Define the display () function here
Output
Element -at index 8: 1
Element at index 1: 3
Element at index 2: 2
Element at index 3: 4
Element at index 4: 5
Element at index 5: 7
Element -at index-6: 6
Element at index 7: 8
Element -at index 8: 9
Element at index 9: 11
Element at index 10: 10e
Element at index 11: 13
Element at index 12: e
Element at index 13: 14](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2Fb3210701-74b9-4350-a073-c4781ff9425b%2Fb982626b-5739-4a48-b038-11ff5fd75728%2F5h9m9vf_processed.png&w=3840&q=75)
Transcribed Image Text:main.c
1. Show me the world
1 #includestdio.h>
by CodeChum Admin
2
// TODO: Declare the display) function here
4
3
Hi Programmer, I'm planning to impress my crush. It seems that
she likes nerd stuff so what I'm planning to do is I want to show
her all of the world array I have.
6" int nain(void) {
int world[100] = {
1,3,2,4,5,7,6,8,9,11,
100,13,0,14,16,17,3,18, 20,10,
12,8,15,14,-5,17,19,18,1,9,5,
10,13,11,14,16 , 22,0,18, 20 ,3,
99,13,15 ,14,22,17,19 ,0, 23,2,
12, 13,15 ,22,16,17,56,18,44,99,
2,13,22,14,16 ,89,19,69, 101,34,
12, 22,15 ,14,78,17,69,18 ,2,33,
4,13,77,7,10,17,19 ,91,4,22,
12,98,15 ,14,15,17,19,18,7
Can you help me with this?
9
10
11
Instructions:
12
13
1. In the code editor, you are provided with the main() function
14
that declares an array with initial values and calls the
15
display() function.
16
2. This display() function hasn't been declared and defined yet.
17
18
This is your task. The details of this function are:
19
1. Return type - void
display (world, 100);
20
2. Name - display
21
3. Parameters
22
return 0;
23 }
1. int* - an array
24
2. int - the size of an array
25 / TODO: Define the display () function here
Output
Element -at index 8: 1
Element at index 1: 3
Element at index 2: 2
Element at index 3: 4
Element at index 4: 5
Element at index 5: 7
Element -at index-6: 6
Element at index 7: 8
Element -at index 8: 9
Element at index 9: 11
Element at index 10: 10e
Element at index 11: 13
Element at index 12: e
Element at index 13: 14
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 4 steps with 2 images

Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you

Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,

C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr

C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning

Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,

C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr

C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning

EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT

Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage