Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true

C Books Guide and List
C++ Books Guide and List
Best Java Books

+1 vote
asked by
edited by

2 Answers

0 votes
yes and no, you can't return more than one variable / object, but as you suggest, you can put them into an array and return that, there is no limit to the nesting of arrays so you can just package them up that way to return
answered by (3.2k points) 6 13 28
0 votes
You can always only return one variable which might be an array. But You can change global variables from inside the function. That is most of the time not very good style, but it works. In classes you usually change class varbiables from within functions without returning them.
answered by (4k points) 5 11 21

Related questions

0 votes
1 answer 72 views
72 views asked by rajesh (39.1k points) 10 21 35
0 votes
1 answer 1k views
1k views asked by carlton (4k points) 5 11 21
+2 votes
4 answers 4.2k views
0 votes
1 answer 22 views
0 votes
1 answer 17 views