Determining salvage value of an item - c# program, DOT NET Programming

Determining salvage value of an item - C# Program

I am a learner of C# language and i am struggling with the programming functions in c#. Can you have any code examples for this.

Posted Date: 2/11/2013 7:19:45 AM | Location : United States





You can get the solution of your problem by using this code.

Program - Determining salvage value of an item

using System;  

class depreciation

{

  public static void Main()

 {

   float depreciation, PurchasePrice, Yrs, SalvageValue; string d,p,y; 

   // string variables are to store the values inputted in the console

   // each string variable has its character as that of the corresponding 

   // starting character of float type variable  

  Console.Write("Enter the Depreciation : ");

  d = Console.ReadLine();

  depreciation = float.Parse(d);  

  Console.Write("Enter the PurchasePrice : ");

  p = Console.ReadLine();

  PurchasePrice = float.Parse(p);  

  Console.Write("Enter the Amount of Years : ");

  y = Console.ReadLine();

  Yrs = float.Parse(y);  

  SalvageValue = (float)(PurchasePrice - (depreciation * Yrs));  

  Console.WriteLine("SalvageValue = " + SalvageValue);  

  Console.ReadLine();  

 }

}

Posted by Alice | Posted Date: 2/11/2013 7:21:33 AM


Related Discussions:- Determining salvage value of an item - c# program, Assignment Help, Ask Question on Determining salvage value of an item - c# program, Get Answer, Expert's Help, Determining salvage value of an item - c# program Discussions

Write discussion on Determining salvage value of an item - c# program
Your posts are moderated
Related Questions
Avoid deadlock in threading The best  and careful planning may avoid deadlocks.There are so many ways Microsoft has provided by which you can decrease deadlocks for example Int

Web Service based application: Aims and Objectives Classics Online is a Web-based book and music retailer specialising in pre-1980s hardback

Project Description: We require some routines written in C# (.NET) to: * Parse several RESTful APIs to change and push data to RabbitMQ * Pop objects from RabbitMQ and inp

What is the namespace in which .NET have the data functionality classes? System.data : This namespace contains the basic objects used for accessing &  storing relational d

Ask queyuyuystion #Minimum 100 words accepted#

What are the precautions by which SQLSERVER Mode work properly Following are the things to keep in mind so that the SQLSERVER Mode works properly:- A) In the SQLSERVER mode,

Project Description: I'm presently seeking at least one more coder that will help me out manage all my concepts and in that way we will share each other's experience and make te

Develop a Face Recognition Systems Project Description: Seeking for someone who has worked with Face Recognition techniques and is familiar with the relevant mathematical alg

Explain the concept of destructor? A destructor is a special method for a class and is requested automatically when an object is finally destroyed. The name of the destructor i

I am seeking someone who can design customized software for me, preferably in .NET. I have a sql server backend which i would like to use so you only have to work with the front en