Program to Convert Pounds to Kilograms in C# – Programming, Pseudocode Example, C# Programming Example
Basic C# Console

Program to Convert Pounds to Kilograms in C#

In this example, we will write a program to convert pounds to kilograms in C#. On the web you will show this example as C# lb to kg convertor.

Firstly we should know the ratio of lbs to kg. The following formula shows the lbs ratio of kg.

1 pound (lb) is equal to 0.45359237 kilograms (kg)= 1 lb = 0.45359237 kg

Example

Convert 5 lb to kilograms: m(kg) = 5 lb × 0.45359237 = 2.268 kg

Pounds to Kilograms conversion table

Pounds (lb)Kilograms (kg) Pounds (lb)Kilograms (kg)
0 lb0 kg 10 lb4.536 kg
0.1 lb0.045 kg 20 lb9.072 kg
1 lb0.454 kg 30 lb13.608 kg
2 lb0.907 kg 40 lb18.144 kg
3 lb1.361 kg 50 lb22.680 kg
4 lb1.814 kg 60 lb27.216 kg
5 lb2.268 kg 70 lb31.751 kg
6 lb2.722 kg 80 lb36.287 kg
7 lb3.175 kg 90 lb40.823 kg
8 lb3.629 kg 100 lb45.359 kg
9 lb4.082 kg 1000 lb453.592 kg

Here is the code how to convert Pounds to Kilograms

Output:

This is a C# program that converts pounds to kilograms. The program has a class called “Program” that contains a Main method, which is the entry point of the program.

In the Main method, the program starts by printing a message to the console asking the user to enter a number in pounds. The user’s input is then read and converted to a double-precision floating-point number using the “Convert.ToDouble” method.

Next, the program calculates the equivalent weight in kilograms by multiplying the weight in pounds by a constant value of 0.45359237. The result is then displayed on the console using the “WriteLine” method.

Finally, the program waits for the user to press the Enter key by calling the “ReadLine” method, which pauses the program until the user inputs something. This allows the user to see the result before the program exits.

2 Comments

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.