Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~271 People Reached
Favorite Forums
Favorite Tags
c++ x 3
Member Avatar for gemacjr

Unable to correct this [code] void main() { char string[20]; char *aString=string; function (aString); } void function(char *name) { cout<< "enter name"; cin >> *name; cout << name; } [/code]

Member Avatar for may4life
0
76
Member Avatar for gemacjr

[code] [COLOR=#0000ff]#include[/COLOR][COLOR=#800000]<iostream>[/COLOR] [COLOR=#0000ff]using [/COLOR][COLOR=#0000ff]namespace[/COLOR][COLOR=#000000] std;[/COLOR] [COLOR=#0000ff]const[/COLOR][COLOR=#0000ff] int[/COLOR][COLOR=#000000] namesize=21;[/COLOR] [COLOR=#0000ff]void[/COLOR][COLOR=#000000] getName([/COLOR][COLOR=#0000ff]char[/COLOR][COLOR=#000000],[/COLOR][COLOR=#0000ff]int[/COLOR][COLOR=#000000]);[/COLOR] [COLOR=#0000ff]void[/COLOR][COLOR=#000000] main()[/COLOR] { [COLOR=#0000ff]int[/COLOR] index=5; [COLOR=#0000ff]int[/COLOR] count; [COLOR=#0000ff]char[/COLOR] names[21]; [COLOR=#0000ff]char[/COLOR] *aString=names; [COLOR=#0000ff]for[/COLOR](count=0;count<index;count++) { [COLOR=#0000ff]char[/COLOR] names; getName(*aString,index); cout << [COLOR=#800000]"You entered: "[/COLOR]; cout << &names; } } [COLOR=#0000ff]void[/COLOR][COLOR=#000000] getName ([/COLOR][COLOR=#0000ff]char[/COLOR][COLOR=#000000] names[][21], [/COLOR][COLOR=#0000ff]int[/COLOR][COLOR=#000000] index)[/COLOR] { cout << [COLOR=#800000]"enter a name: "[/COLOR]; cin …

Member Avatar for Ancient Dragon
0
87
Member Avatar for gemacjr

[COLOR=#0000ff][code]#include<[/code][/COLOR][code=c][color=#800000]iostream>[/color] [color=#0000ff]using [/color][color=#0000ff]namespace[/color][color=#000000] std;[/color] [color=#0000ff]consta[/color]code][color=#0000ff]nt[/color][color=#000000] namesize=21;[/color] [color=#0000ff]void[/color][color=#000000] getName([/color][color=#0000ff]char[/color][color=#000000],[/color][color=#0000ff]int[/color][color=#000000]);[/color] [color=#0000ff]int[/color][color=#000000]main()[/color] { [color=#0000ff]int[/color] index=5; [color=#0000ff]int[/color] count; [color=#0000ff]char[/color] names[21]; [color=#0000ff]char[/color] *aString=names; [color=#0000ff]for[/color](count=0;count<index;count++) { [color=#0000ff]char[/color] names; getName(*aString,index); cout << [color=#800000]"You entered: "[/color]; cout << &names; } } [color=#0000ff]void[/color][color=#000000] getName ([/color][color=#0000ff]char[/color][color=#000000] names[][21], [/color][color=#0000ff]int[/color][color=#000000] index)[/color] { cout << [color=#800000]"enter a name: "[/color]; cin >> names[index]; } …

Member Avatar for John A
0
108