Go Back   CodingForums.com > :: Computing & Sciences > Computer Programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 02-23-2010, 06:40 PM   PM User | #1
coderyc
New to the CF scene

 
Join Date: Feb 2010
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
coderyc is an unknown quantity at this point
Solution to C programming exercise ??

Hi,
I'm a newbie and cant solve this programming exercise!

Given this structure:

typedef struct ContactRecord
{
char name[16];
unsigned char number[20];
}ContactRecord;

static ContactRecord ContactTable[MAX_ENTRIES];

Exercise: Write a C function to write a name and number to any single record of the above ContactTable data structure.

Any ideas/suggestions??

Thanks,
yc
coderyc is offline   Reply With Quote
Old 02-23-2010, 07:05 PM   PM User | #2
tomws
Senior Coder

 
tomws's Avatar
 
Join Date: Nov 2007
Location: Arkansas
Posts: 2,644
Thanks: 29
Thanked 330 Times in 326 Posts
tomws will become famous soon enoughtomws will become famous soon enough
I suggest you read your course notes and text. Aside from that, if you have a specific question, ask it.
__________________
Are you a Help Vampire?
tomws is offline   Reply With Quote
Old 02-23-2010, 09:31 PM   PM User | #3
oracleguy
Rockstar Coder


 
Join Date: Jun 2002
Location: USA
Posts: 9,043
Thanks: 1
Thanked 322 Times in 318 Posts
oracleguy is a jewel in the roughoracleguy is a jewel in the roughoracleguy is a jewel in the rough
Quote:
Originally Posted by tomws View Post
I suggest you read your course notes and text. Aside from that, if you have a specific question, ask it.
Exactly. You need to ask a specific question, per our rules we cannot just do the assignment for you. What is it that you are confused or unsure about?
__________________
OracleGuy
oracleguy is offline   Reply With Quote
Old 02-23-2010, 11:21 PM   PM User | #4
BrickInTheWall
Regular Coder

 
BrickInTheWall's Avatar
 
Join Date: Mar 2009
Location: Munich, Germany
Posts: 139
Thanks: 1
Thanked 13 Times in 13 Posts
BrickInTheWall is on a distinguished road
The other posters are right.
If you know how to write a function, look at the question. You basically have to fill the members of an instance of the struct...what arguments would the function need?
__________________
Call me Brick, if you like!
BrickInTheWall is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 06:46 PM.


Advertisement
Log in to turn off these ads.