Jump to content

Trigonometric functions: Difference between revisions

Added Easylang
No edit summary
(Added Easylang)
 
(One intermediate revision by one other user not shown)
Line 1,179:
0.7853981633974483 45.0
0.7853981633974483 45.0
 
=={{header|EasyLang}}==
<syntaxhighlight>
r = pi / 4
d = 45
#
func r2d r .
return r / pi * 180
.
func d2r d .
return d * pi / 180
.
#
numfmt 4 0
print sin d & " " & sin r2d r
print cos d & " " & cos r2d r
print tan d & " " & tan r2d r
print ""
h = asin sin d
print h & " " & d2r h
h = acos cos d
print h & " " & d2r h
h = atan tan d
print h & " " & d2r h
</syntaxhighlight>
 
{{out}}
<pre>
0.7071 0.7071
0.7071 0.7071
1.0000 1.0000
 
45.0000 0.7854
45 0.7854
45 0.7854
</pre>
 
=={{header|Elena}}==
Line 5,523 ⟶ 5,559:
{{trans|Go}}
{{libheader|Wren-fmt}}
<syntaxhighlight lang="ecmascriptwren">import "./fmt" for Fmt
 
var d = 30
1,978

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.