![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Nov 2006
Posts: 8
Rep Power: 0
![]() |
New to the forum, need a bit of help/guidance re C#
I have to write a program using C# for an assignment,
basically the program must work out the amount tat each person should pay towards a tea kitty each week. Each person drinks drinks drinks a day. 1 pint of milk makes 1 drinks, the teabags come in boxes of 480 teabags(1 teabag makes 1 drink) and the bag of sugar is used to make 100 drinks. i obviously declare the variables at the start i got that bit but its the rest of the program I just dont know where to start(im not askin for someone to do it for me but for some pointers), Id appreciate your help alot, Last edited by DC_FC79; Nov 18th, 2006 at 5:41 AM. |
|
|
|
|
|
#2 |
|
Programming Guru
![]() Join Date: Aug 2005
Location: England
Posts: 1,499
Rep Power: 5
![]() |
Well, it's simple arithmetic, no? Write down the equations you'd use to calculate it manually, and then convert them into C# code.
|
|
|
|
|
|
#3 |
|
Newbie
Join Date: Nov 2006
Posts: 8
Rep Power: 0
![]() |
ok so i do the calculations but its how to write it into the program, what lines of code to use
are there any sites i can have a look at for a quick tutorial on C# |
|
|
|
|
|
#4 |
|
Expert Programmer
Join Date: Aug 2005
Location: Rotterdam, the Netherlands
Posts: 942
Rep Power: 4
![]() |
Use Google.
I think it's rather weird that you have to write a program for an assignment, and you don't even know how to do simple arithmetics. |
|
|
|
|
|
#5 |
|
Programming Guru
![]() Join Date: Aug 2005
Location: England
Posts: 1,499
Rep Power: 5
![]() |
Well, I'll give you an example similar to your problem. Lets say you want to create a program that converts Fahrenheit into degrees Celsius. It might look something like this:
c# Syntax (Toggle Plain Text)
|
|
|
|
|
|
#6 |
|
Newbie
Join Date: Nov 2006
Posts: 8
Rep Power: 0
![]() |
|
|
|
|
|
|
#7 | |
|
Newbie
Join Date: Nov 2006
Posts: 8
Rep Power: 0
![]() |
Quote:
ill have a go at changing the bits necessary for me |
|
|
|
|
|
|
#8 |
|
Programming Guru
![]() Join Date: Aug 2005
Location: England
Posts: 1,499
Rep Power: 5
![]() |
|
|
|
|
|
|
#9 |
|
Programmer
Join Date: Jul 2006
Location: using Earth.Africa.Egypt.Cairo;
Posts: 76
Rep Power: 3
![]() |
Have you ever write any thing in C# before ????
|
|
|
|
|
|
#10 | |
|
Expert Programmer
|
Quote:
__________________
|
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Introduction forum, Moved | big_k105 | Community Announcements and Feedback | 12 | Nov 3rd, 2005 10:06 AM |
| PHP forum script | grimpirate | PHP | 32 | Sep 19th, 2005 11:08 PM |
| Forum FAQs?? | DaWei | Community Announcements and Feedback | 8 | Sep 3rd, 2005 1:47 PM |