1 | math.sin( x ) ;' |! m0 l+ Z, X; @4 d- }; u0 v8 [7 W8 K " j9 Y. v: N4 t2 a( m6 J |
1% d8 _. t4 B6 x/ ` 2: i& E* `2 N% N3 ^- a) B, P" j 32 k w, H' t1 j+ v5 t' k 4 5 6# F) Y2 g2 U* A+ ] 70 y, x, ~; J# e. m 85 I9 t; `7 h& _, \ 9 10! g, l4 R Z" W v+ t 11( w# _2 l5 }3 P$ | 12 13. [; j2 }) s2 Y# Y 14+ `$ P4 M/ ~. W/ m 15 16 17) X8 H. Q' j6 E3 L/ q 18 19 20 21 M( ?+ F1 z) G. o1 F | <html> <head>4 d# Q6 | ^- J: t <title>javascript math sin() method</title> </head> <body> <script type="text/javascript"> ! Z; J$ v/ N+ s8 Z" L var value = math.sin( 0.5 );- A% f4 S# |, ?; E j# j document.write("first test value : " + value ); var value = math.sin( 90 ); document.write("<br />second test value : " + value ); 2 h6 _8 J# @+ l$ U var value = math.sin( 1 ); document.write("<br />third test value : " + value ); 6 f1 B3 q3 \* @" |; p' J var value = math.sin( math.pi/2 );8 f$ s* p0 K* r+ q# ]. r document.write("<br />fourth test value : " + value ); </script> </body> a3 i5 D) W$ L' _ </html> |
17 T) q6 o1 \! m9 \* f 2 e: l$ }, ~0 R1 R. \7 h8 b% x 3) b5 j* l- U0 \8 r6 ^9 a8 f& P 4 | first test value : 0.479425538604203 k+ i& g' o# c2 ~( U. p second test value : 0.8939966636005578$ r+ ?7 v+ S9 o third test value : 0.8414709848078965. ~% r! m# [( j0 } g( ~0 I fourth test value : 19 Q5 @* v* s Q |
欢迎光临 得知互动 (https://bbs.dezhifl.com/) | Powered by Discuz! X3.4 |