JavaScript Statement document.write(&#34; -10.0 / 0)是&#34; + 10.0 / 0 +&#39; <BR/>&#39);

时间:2016-08-14 05:20:43

标签: javascript

我希望答案为-Infinity但我得到无限作为答案,这些是我测试的其他陈述。

&#13;
&#13;
document.write("10/0 is "+ 10/0+'<br>');
document.write("-10/0 is "+ -10/0+'<br>');
document.write("10.0/0 is " +10.0/0+'<br>');
document.write("-10.0/0) is " +10.0/0+'<br>');/* ** */
  document.write("0/0  is "+0/0+'<br>');
&#13;
&#13;
&#13;

所有上述陈述都根据JavaScript这样的规则产生了完美的结果

10/0 is Infinity
-10/0 is -Infinity
10.0/0 is Infinity
-10.0/0) is Infinity
0/0 is NaN

除了问题中的那个,kiindly看看它谢谢。

1 个答案:

答案 0 :(得分:1)

{
   "error_message" : "You have exceeded your daily request quota for this API.",
   "routes" : [],
   "status" : "OVER_QUERY_LIMIT"
}