Programming Examples

Write a Python code to calculate and display the value of Sine 45° and Cosine 30°


Write a Python code to calculate and display the value of Sine 45° and Cosine 30°

import math
a=45;b=60
x = 22/(7*180)*a
y = 22/ (7*180)*b
sn= math.sin(x)
cs= math.cos(y)
print("The value of Sine 45 degree =",sn)
print("The value of Cosine 60 degree =",cs)
Output

The value of Sine 45 degree = 0.7073302780849811

The value of Cosine 60 degree = 0.4996349289865546

Online Exam Quiz for One day Exam Online Typing Test CCC Online Test 2026 Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Best Website and Software Company in Allahabad