Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: Help needed in C# - programming  (Read 3855 times)

0 Members and 1 Guest are viewing this topic.

dr_iton

    Topic Starter


    Intermediate
  • Reading jeopardizes stupidity?
  • Thanked: 6
    • PERSONAL WEB SITE
  • Certifications: List
  • Experience: Experienced
  • OS: Windows 10
Help needed in C# - programming
« on: December 26, 2011, 11:32:14 AM »
Please I'm a beginer in C#, so if you just can give me a suggestion about how to solve the following problem.

Vehicle manufacturers always offer new saving fuel cars to new drivers. The Renault manufacturer has taken this in consideration and offered new car Renault Clio to a driver Syle LeSylani for one year use. Syle has kept evidence of past kilometers at every fuel filling. He made at least 5 reservoirs filling per year.
 
My duty is to write the C# program that it will accept fuel data (type: double) and past kilometers (type: double) for every fuel filling. The program it needs to process those data in console application, how many kilometers are past in each filling. Also it needs to show overall calculation of past kilometers for all fillings. The calculation must be presented in decimal (real numbers). The class and the program should be in two separate files. 


I have to wirte the pseudocode of this to.

In advance thank you for your reply.
Cheers.


A MARATHON BEGIN'S WITH A FIRST STEP.

Rob Pomeroy



    Prodigy

  • Systems Architect
  • Thanked: 124
    • Me
  • Experience: Expert
  • OS: Other
Re: Help needed in C# - programming
« Reply #1 on: December 27, 2011, 08:23:20 AM »
Pseudocode is not C#.  You're being asked to express this in simple statements.  It's homework by the looks of it, so your best advantage would come from having a go and then asking for comments.  There are plenty of examples of pseudocode on the internet which will give you a better idea of what you're trying to achieve.  Hint: it's simpler than it sounds.

The idea is that once you've written the pseudocode, converting that to C# (or any other language) is a breeze.
Only able to visit the forums sporadically, sorry.

Geek & Dummy - honest news, reviews and howtos

dr_iton

    Topic Starter


    Intermediate
  • Reading jeopardizes stupidity?
  • Thanked: 6
    • PERSONAL WEB SITE
  • Certifications: List
  • Experience: Experienced
  • OS: Windows 10
Re: Help needed in C# - programming
« Reply #2 on: December 27, 2011, 11:03:59 AM »
@ Rob Pomeroy
I know that pseudocode isn't in C# but I just explained what I have to do.
About the program, I almost done it, but just asked for the help. It is a little to difficoult to me because I just started learning C#. I know that in the begining fuel and km's must be 0 because it is a new car. At least 5 fuel fillings per year mut be done.
The problem is that I'm stucked in a place where where it is asked to show how many km/one liter.
I get some errors and just fixing them.

Cheers.


A MARATHON BEGIN'S WITH A FIRST STEP.

BC_Programmer


    Mastermind
  • Typing is no substitute for thinking.
  • Thanked: 1140
    • Yes
    • Yes
    • BC-Programming.com
  • Certifications: List
  • Computer: Specs
  • Experience: Beginner
  • OS: Windows 11
Re: Help needed in C# - programming
« Reply #3 on: December 27, 2011, 01:45:43 PM »
Where is what you have so far?
I was trying to dereference Null Pointers before it was cool.

Rob Pomeroy



    Prodigy

  • Systems Architect
  • Thanked: 124
    • Me
  • Experience: Expert
  • OS: Other
Re: Help needed in C# - programming
« Reply #4 on: December 28, 2011, 07:05:33 AM »
The problem is that I'm stucked in a place where where it is asked to show how many km/one liter.

Is the problem to do with getting the formula correct, or something else?
Only able to visit the forums sporadically, sorry.

Geek & Dummy - honest news, reviews and howtos

dr_iton

    Topic Starter


    Intermediate
  • Reading jeopardizes stupidity?
  • Thanked: 6
    • PERSONAL WEB SITE
  • Certifications: List
  • Experience: Experienced
  • OS: Windows 10
Re: Help needed in C# - programming
« Reply #5 on: January 19, 2012, 03:15:54 PM »
I had a problem on writing the codes, so after a time I solved (learned) it.
Anyway cheers for your help.


A MARATHON BEGIN'S WITH A FIRST STEP.