corsasport.co.uk
 

Corsa Sport » Message Board » General Chat » C Programming


New Topic

New Poll
  Subscribe | Add to Favourites

You are not logged in and may not post or reply to messages. Please log in or create a new account or mail us about fixing an existing one - register@corsasport.co.uk

There are also many more features available when you are logged in such as private messages, buddy list, location services, post search and more.


Author C Programming
luca2020
Member

Registered: 26th May 02
Location: Maidstone, Kent
User status: Offline
17th Jul 04 at 18:45   View User's Profile U2U Member Reply With Quote

Is anyone good at it?

if so please say i need your help badly
Andrew
Member

Registered: 5th May 04
Location: Skoda Octavia Estate, Ford Puma
User status: Offline
17th Jul 04 at 18:47   View User's Profile U2U Member Reply With Quote

I'm not good at it but know a little bit
Ian
Site Administrator

Avatar

Registered: 28th Aug 99
Location: Liverpool
User status: Offline
17th Jul 04 at 19:26   View Garage View User's Profile U2U Member Reply With Quote

Go on...
luca2020
Member

Registered: 26th May 02
Location: Maidstone, Kent
User status: Offline
18th Jul 04 at 01:22   View User's Profile U2U Member Reply With Quote

well i have referal work at uni to be in for next friday, and im usuless at c programming, ive got a few books but dont really answer the questions i gotta answere

Here are the questions:

Write an essay entitled "Data Storage and Functions in C". Your essay must have a maximum
length of 5 sides and cover the following topics:

1 Data Storage
Explain, using diagrams to support your explanation, how you might arrange
to hold information about stock items in a shop where:
a. The information held for each item should include:
Item name (e.g. Corn Flakes, Coca Cola)
Item details (e.g. 500 gm packet, six pack)
Price
Barcode number
Number in stock
Minimum stock level.
b. The shop may carry up to 1000 stock items.
20 marks

Give examples of appropriate C declarations to do this, and examples of C
code which to put information into the store and use information from the
store.
20 marks

2 Functions
Outline the reasons for using functions in a program. 20 marks

Explain, with examples, how data can be passed into a function using
parameters. Your explanation should cover passing both single values and
arrays.
20 marks

Explain, with examples, how data can be passed out of a function using
parameters and return statements. Again, your explanation should cover
passing both single values and arrays, as well as the data structure you
generated in part 1 above.
20 marks

i can do the 1st question of part 2, thats it lol, any help anyone?
Russ
Member

Registered: 14th Mar 04
Location: Armchair
User status: Offline
18th Jul 04 at 09:25   View User's Profile U2U Member Reply With Quote

i can help..

do another subject, pc's aint ur shit...
luca2020
Member

Registered: 26th May 02
Location: Maidstone, Kent
User status: Offline
18th Jul 04 at 09:44   View User's Profile U2U Member Reply With Quote

ur so helpful mate, thanx

and why aint computers my shit? because im usless at c programming means im shit with computers? i got over 65% on every other subject with out trying in my 1st year at uni, tit
Ian
Site Administrator

Avatar

Registered: 28th Aug 99
Location: Liverpool
User status: Offline
18th Jul 04 at 10:42   View Garage View User's Profile U2U Member Reply With Quote

Thats all fairly textbook stuff, nothing a bit of research won't fix.
Joff
Member

Registered: 17th Oct 00
Location: Cambridgeshire
User status: Offline
18th Jul 04 at 10:47   View User's Profile U2U Member Reply With Quote

So basically you need to investigate what data types are available and what functions are built into C for storing/accessing arrays, etc.

Why not look for example stock system/shopping cart code and see what datatypes they're using.
luca2020
Member

Registered: 26th May 02
Location: Maidstone, Kent
User status: Offline
18th Jul 04 at 20:21   View User's Profile U2U Member Reply With Quote

Thanx ian and joff, ive tryed 2 librays at home and they have little on programming, i did manage to find 2 c books tho, 1 called 'The C Programming Language' by Brian W.Kernigham and another book called 'Turbo C/C++' by Herbert Schildt

Do you have any recomendations of the top of your head?

thanx for the help anyway lads
Dom
Member

Registered: 13th Sep 03
User status: Offline
18th Jul 04 at 20:31   View User's Profile U2U Member Reply With Quote

aye, like ian said textbox stuff. I dont know C, but know other programming languages, and it looks pretty basic when you break the questions down.

i mean, functions...dead easy question, one reason is that it allows you recall an routine without having to repeat the code more than once etc

2nd question about declarations is pretty easy..dunno bout the first part, but the 2nd part of the question would be to write the code used to access the data storage (your using, database i would believe).

last two question would involve demostrating the code and explaining it (copy out of a textbook mate ).

and the first question is pretty easy too, i would just show screen grabs of your data storage method


however, tbh mate, all of this should have been learnt during class eitherway, i would speak to your tutor if your unsure of stuff
also, just do a google search for C data storage methods and databases etc
Joff
Member

Registered: 17th Oct 00
Location: Cambridgeshire
User status: Offline
18th Jul 04 at 20:33   View User's Profile U2U Member Reply With Quote

How much of C do you understand?

Concepts about datatypes are universal to pretty much any language, with only the syntax for their use changing.
There should be plenty of on-line lecture notes giving good pointers (ahem) for areas you should be investigating.
Andrew
Member

Registered: 5th May 04
Location: Skoda Octavia Estate, Ford Puma
User status: Offline
18th Jul 04 at 20:33   View User's Profile U2U Member Reply With Quote

Bloody hell they want that done quick I've got an referal maths exam to do but that's not until August 16th.

It's a nice and easy course-work to do that mate. I'll swop maths for c programming anyday There's loads and loads of books about you can just *copy* from
Aaron02
Member

Registered: 26th Feb 03
User status: Offline
18th Jul 04 at 20:38   View User's Profile U2U Member Reply With Quote

www.programmersheaven.com, this is a good forum to ask the pro's questions on many programming languages

i've learnt alot from the people on that forum
Joff
Member

Registered: 17th Oct 00
Location: Cambridgeshire
User status: Offline
18th Jul 04 at 20:43   View User's Profile U2U Member Reply With Quote

http://publications.gbdirect.co.uk/c_book/

Copying code is ideal if you can read and understand what's going on and why something's been done in a certain way, but it's careless to submit something you've got no idea on because it's likely you'll be questioned on certain parts!
Ian
Site Administrator

Avatar

Registered: 28th Aug 99
Location: Liverpool
User status: Offline
18th Jul 04 at 22:17   View Garage View User's Profile U2U Member Reply With Quote

Just remembered some parameter passing stuff I did at uni, its not the exact stuff I covered but you could do a lot worse than having a quick look over it, see if it ties in with what you're being assessed on.

http://www.csc.liv.ac.uk/~grant/Teaching/COMP205/paramPassing.html



[Edited on 18-07-2004 by Ian]

 
New Topic

New Poll

Corsa Sport » Message Board » General Chat » C Programming 23 database queries in 0.0161941 seconds