KidzTalk

How do you return a pointer to an array in C++?

+10 votes
51 views
asked Oct 3, 2019 in Science by gary
Im am only 7 yers old so i need abit of help witrh this. How do i return a pointer to an array from a function in c++. thanks guys


3 Answers

+1 vote
answered Oct 5, 2019 by Kitten (563,880 points)

Way-1

Formal parameters as a pointer as follows −

void myFunction(int *param) {
   .
   .
   .
}

Way-2

Formal parameters as a sized array as follows −

void myFunction(int param[10]) {
   .
   .
   .
}

Way-3

Formal parameters as an unsized array as follows −

void myFunction(int param[]) {
   .
   .
   .
}
commented Dec 18, 2019 by Kitten (563,880 points)
did this help?
+1 vote
answered Oct 4, 2019 by toad aka star (342,820 points)
I'm in 7th grade and I have no idea what you are talking about, and I just don't know if I'm just dumb 'coz I'm doing okay at school
commented Oct 5, 2019 by Kitten (563,880 points)
You are not dumb. C ++ is a computer software language that makes up the MS DOS and windows 96, XP, vista, 7, 8.1, and 10 operating systems. Most people just don't know that.
commented Oct 5, 2019 by toad aka star (342,820 points)
Oh, thank goodness lol.
commented Dec 18, 2019 by Kitten (563,880 points)
:D
+2 votes
answered Oct 3, 2019 by Puppy (2,980 points)
Are you makong computer software?

Related questions

+9 votes
2 answers 20 views

How do you download an app with a QR code? Where do you go to scan it? Please Help Me!!!

asked Jan 13 in Other by PrincessKittens Left (201,830 points)
+11 votes
15 answers 397 views

Almost all my friends have a boyfriend, or has been asked out... but i havent Am i just ugly, well, i have been asked out by guys MUCH older than me. But thats gross and ... my friends (who is a girl and im straight) asked me out augh what do I do?!

asked Nov 26, 2018 in Other by Strawberry J.A.M
+10 votes
1 answer 59 views

How do you clear browser cache on a Samsung tablet?

asked Jul 18, 2019 in Technology by Luna midnight
+5 votes
3 answers 23 views

I have an acount you can guess it fif u want, & i cant reshow a few questions that I hid.

asked Feb 12 in KidzSearch Tech Support by I ain't tellin'
+42 votes
232 answers 1,129 views

FEATURED IN THE KIDZSEARCH MAGAZINE Change log - click HERE for full update history July 17 2019: Origional version created October 29 2019: Added a paragraph about the ... design Febuary 25 2020: added a change log Febuary 27 2020: new design!

asked Jul 17, 2019 in KidzSearch Contests by Kitten (563,880 points)
+7 votes
1 answer 59 views
+9 votes
10 answers 76 views

I have a crush on this girl who 99.999% does not like me back. How do I get her to like me?

asked Jan 17 in Personal by Jabber (24,230 points)
+9 votes
2 answers 70 views

I don't know how to!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

asked Jan 12, 2019 in Personal by unicornlover01 (1,320 points)
+9 votes
9 answers 375 views

asked May 17, 2016 in Other by Horselover101
+7 votes
6 answers 32 views

My doctor says I have Strep Throat!!!!!!!!!!! Can you please give me advice? Thanks, WelshTerriersss

asked Feb 4 in Personal by WelshTerriersssCS (13,860 points)
+8 votes
1 answer 38 views

First off this is gonna be a lot of stuff about the three R's and Earth-Chan. Mostly Earth-Chan and how you can help her. Earth-Chan is very sick from pollution in ... There are many small things you can do to save Earth-Chan, will you Do Your Part?

asked Dec 17, 2019 in Do Your Part by LunaLight (90,090 points)
+10 votes
1 answer 126 views

I want an advise column that is like the creative kidz club but a column instead where people can get help with crafts or writings of any sort. I would like ... questions if she would like to. Depending on what gemmy says will deside the name.

asked Oct 20, 2018 in Ask KidzSearch by LunaLight (90,090 points)
+9 votes
5 answers 106 views

I am in middle school and none of my really close friends from elementary school go to my school. I am shy but I still want to make close friends. Please help me pop my bubble and make some friends.

asked Dec 4, 2018 in Personal by fungirly24 (1,660 points)
+7 votes
4 answers 40 views

KidzNet! Something that has Kitty or Kat. I have tried Im.Kitty.Kat (doesn't work) Kitty_Kat (doesn't work), I.Am.A.Kat (doesn't work) Please help!

asked Nov 13, 2019 in Other by ❤KittyKat❤ (101,600 points)
+8 votes
3 answers 52 views

Do emails get sent if a KT user changes their username?

asked Sep 29, 2019 in Ask KidzSearch by LunaLight (90,090 points)
+7 votes
4 answers 24 views

KidzSearch, I need help! When I typed in my password, it said, "User not found." Help me please!!!!!!!!!!!!!

asked Jan 31 in Ask KidzSearch by WelshTerriersss
+10 votes
4 answers 54 views

Hey Girls Advice Column! Sometimes, I feel really stupid. Like a few days ago, I was at school and my friends were laughing at something. I laughed too, thinking it was ... this isn't the only time I feel left out with them. What should I do?

asked Jan 7 in Girls' Advice Column by Cupcake
+7 votes
2 answers 35 views
+9 votes
4 answers 60 views

Omg I need help on multiplication I'm starting division help meeeeeeeeeeeeeeeeeeeee!!!!!!!

asked Nov 27, 2019 in Homework Help by Ju Ju Bee (350 points)
+10 votes
4 answers 62 views

I am in seventh grade and today we just had and english test, quick problem i only just found out about that test 30 before the test, so i did not have time to study. I am pretty sure that i am gonna fail

asked Nov 10, 2019 in Homework Help by Jabber (24,230 points)
+9 votes
2 answers 62 views

Hi! So, I have a complicated situation. I would like to start by saying that I and my Mum don't have the greatest relationship. I went away to camp for ten days this ... I'm homesick for a place other than home, if that's possible. What should I do?

asked Aug 10, 2019 in Personal by Rebekah<3Raven (3,920 points)
+11 votes
2 answers 78 views

Should I make an advise column? I don't know, but how many points do I need? I barely have any points! If so, any ideas? I was thinking more of stories, like Luna ... a contest? I want to make it a contest! What kind do you guys seems interested in?

asked Oct 30, 2018 in Debate by toad aka star (342,820 points)
+10 votes
5 answers 278 views

I have a crush on someone and he and one of my friends like each other. How do I get over him?

asked Feb 6, 2018 in All Advisors by Meow
+13 votes
2 answers 71 views

As some of you may know, i have been working on idea for an anti-bullying program in my school. I have been searching Google but still need more ... websites or facts regarding bullying statistics, please post them in the answers, thank you.

asked Jul 17, 2019 in Personal by LunaLight (90,090 points)

Recent Badges

Notable Question
Asked question received 50 views
- ❤️GryffindorGal❤️ -
Nice Comment
Comment received +2 upvote
- jellyfishlover -
Nice Comment
Comment received +2 upvote
- Coffee Cake -
Nice Comment
Comment received +2 upvote
- jellyfishlover -
Nice Answer
Answer received +2 upvote
- Coffee Cake -
...