# Program to convert Degree to Radian

Given the angle in **degree**, the task is to convert this into radians.

**Examples:**

Input:degree = 45Output:radian = 0.785398Input:degree = 58Output:radian = 1.01229

**Approach:**

**Radian:** The Radian is the SI unit for measuring angles, used mainly in trigonometry. A radian is defined by an arc of a circle. A full circle is just over 6 radians (Roughly 6.28). One radian is just under 57.3 degrees.

**Degree:** A degree, usually denoted by ° (the degree symbol), is a measurement of a plane angle, defined so that a full rotation is 360 degrees. Because a full rotation equals 2*pi radians, one degree is equivalent to pi/180 radians.

The formula to convert radian to degree is:

radian = degree * (pi/180)where pi = 22/7

Below is the implementation of the above approach:

## C++

`// C++ program to convert degree to radian ` ` ` `#include <iostream> ` `#include <math.h> ` `using` `namespace` `std; ` ` ` `// Function for conversion ` `double` `Convert(` `double` `degree) ` `{ ` ` ` `double` `pi = 3.14159265359; ` ` ` `return` `(degree * (pi / 180)); ` `} ` ` ` `// Driver code ` `int` `main() ` `{ ` ` ` `double` `degree = 30; ` ` ` `double` `radian = Convert(degree); ` ` ` `cout << radian; ` ` ` `return` `0; ` `} ` |

*chevron_right*

*filter_none*

## Java

` ` `// Java program to convert degree to radian ` `import` `java.io.*; ` `import` `java.util.*; ` ` ` `class` `GFG { ` ` ` `// Function for conversion ` `static` `double` `Convert(` `double` `degree) ` `{ ` ` ` `double` `pi = ` `3.14159265359` `; ` ` ` ` ` `return` `(degree * (pi / ` `180` `)); ` `} ` ` ` `// Driver code ` `public` `static` `void` `main(String[] args) ` `{ ` ` ` `double` `degree = ` `30` `; ` ` ` `double` `radian = Convert(degree); ` ` ` ` ` `System.out.printf(` `"%.6f"` `, radian); ` `} ` `} ` ` ` `// This code is contributed by coder001 ` |

*chevron_right*

*filter_none*

## Python3

`# Python3 program to convert degree to radian ` ` ` `# Function for conversion ` `def` `Convert(degree): ` ` ` ` ` `pi ` `=` `3.14159265359` `; ` ` ` `return` `(degree ` `*` `(pi ` `/` `180` `)); ` ` ` `# Driver code ` `degree ` `=` `30` `; ` `radian ` `=` `Convert(degree); ` `print` `(radian); ` ` ` `# This code is contributed by Code_Mech ` |

*chevron_right*

*filter_none*

## C#

`// C# program to convert degree to radian ` `using` `System; ` ` ` `class` `GFG{ ` ` ` `// Function for conversion ` `static` `double` `Convert(` `double` `degree) ` `{ ` ` ` `double` `pi = 3.14159265359; ` ` ` ` ` `return` `(degree * (pi / 180)); ` `} ` ` ` `// Driver code ` `public` `static` `void` `Main() ` `{ ` ` ` `double` `degree = 30; ` ` ` `double` `radian = Convert(degree); ` ` ` ` ` `Console.Write(` `"{0:F6}"` `, radian); ` `} ` `} ` ` ` `// This code is contributed by Code_Mech ` |

*chevron_right*

*filter_none*

**Output:**

0.523599

Don’t stop now and take your learning to the next level. Learn all the important concepts of Data Structures and Algorithms with the help of the most trusted course: **DSA Self Paced**. Become industry ready at a student-friendly price.

## Recommended Posts:

- Program to Convert Radian to Degree
- Program to convert temperature from degree Celsius to Kelvin
- Program to convert a given number to words
- Program to Convert Octal to Hexadecimal
- Java program to convert Currency using AWT
- Program to convert Number in characters
- Program to convert a given number to words | Set 2
- Program to convert Centimeter to Feet and Inches
- Program to convert a BCD to Hexa-Decimal Number
- Program to convert centimeter into meter and kilometer
- Program to Convert Hexadecimal Number to Binary
- Python Program to convert Kilometers to Miles
- Program to convert speed in km/hr to m/sec and vice versa
- Program to convert KiloBytes to Bytes and Bits
- Program to Convert Km/hr to miles/hr and vice versa
- Program to convert Hexa-Decimal Number to its equivalent BCD
- Rotate a Matrix by 180 degree
- Nodes with prime degree in an undirected Graph
- Make a tree with n vertices , d diameter and at most vertex degree k
- Print the nodes with a prime degree in given Prufer sequence of a Tree

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.