Java笔试题目2附答案_第1页
Java笔试题目2附答案_第2页
Java笔试题目2附答案_第3页
Java笔试题目2附答案_第4页
Java笔试题目2附答案_第5页
已阅读5页,还剩4页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、Java笔试题目2JAVASCRIPT Interview Questions and Answer您的姓名: 填空题 *_电话号码: 填空题 *_1. Add embedded javacript in the blank, which will call “alert(here)”.Page Title 填空题 *_2. Add a javacript file “myjavascript.js” in the blank.Page Title填空题 *_3. Is JavaScript case sensitive? 填空题 *_4. What are the types used in

2、 JavaScript? 填空题 *_5. What are the boolean operators supported by JavaScript? 填空题 *_6. What is the difference between “=” and “=”? 填空题 *_7. How to access the value of the textbox in following html using JavaScript? Full name: 填空题 *_8. Fill in the blank to comment out the following lines:.is used for

3、 line comments.this isblock comment example.填空题 *_(答案:请设置答案)9. There is a checkbox in html file, the id of the checkbox is checkbox1. How will you get the Checkbox status whether it is checked or not? 填空题 *_10. Provide two examples of creating arrays in JavaScript. 填空题 *_11. If an array with name as

4、 names contain three elements, then how will you print the third element of this array? 填空题 *_12. There is only one form in the html document, How do you submit it using JavaScript? 填空题 *_13. What is the output of the following scripts? document.write(isNaN(Hello)+ );document.write(isNaN(2013/06/23)

5、+ );document.write(isNaN(123)+ );填空题 *_14. How to get the value of PI in JavaScript? 填空题 *_15. What is the output of following scripts? var obj = outerWidth : 20 ;function say() console.log(this.outerWidth);say(); say.apply(obj); 填空题 *_16. What does 1+2+4 evaluate to? 填空题 *_17. What does 3+4+7 evalu

6、ate to? 填空题 *_18. There is a label in the document, and the id of the label is “myText”. Provide javascripts to change the fontSize of the label to 20, and change the className to “anyclass”. 填空题 *_19. Create the man object, with following properties: name: Bill Gates , living: “ true”, age: 27. 填空题

7、 *_20. Add getName function to the above man object, which will display mans name in the console.log. 填空题 *_21. What is output of the following statements? var myString = new String(male);var myStringLiteral = male;console.log(myString.constructor, myStringLiteral.constructor);填空题 *_22. What will be

8、 the output of the following statements?var myString = Vikas / Create a primitive string object.var myStringCopy = myString; / Copy its value into a new variable.var myString = null; / Manipulate the valueconsole.log(myString, myStringCopy);填空题 *_23. Consider the following statements and tell what w

9、ould be the output of the logs statements? var price1 = 10;var price2 = 10;var price3 = new Number(10); / A complex numeric object because new was used.console.log(price1 = price2); console.log(price1 = price3);填空题 *_24. What would be the output of the following statements? var object1 = same: same

10、;var object2 = same: same ;console.log(object1 = object2);填空题 *_25. What would be the output of the following statements?var object1 = same: same ;var object2 = object1;console.log(object1 = object2);填空题 *_26. What is this? var myArray = ;填空题 *_27. Name any two JavaScript functions which are used to

11、 convert nonnumeric values into numbers? 填空题 *_28. What would be the output of the following statements?var s = 5;var a = s*1;var b = +s;console.log(typeof(s); console.log(typeof(a); console.log(typeof(b); 填空题 *_29. What would be the output of the following statements?var a = 1;function f() var b =

12、1;return a;console.log(f();console.log(b);填空题 *_30. What would be the output of the following statements?var a = global variable;var F = function () var b = local variable;var N = function () var c = inner local;return b;return N;var inner = F();inner();填空题 *_31. What would be the output of the foll

13、owing statements?function F() var arr = , i;for (i = 0; i 3; i+) arri = (function (x) return function () return x;(i);return arr;var arr = F();arr1();填空题 *_32. What would be the output of the following statements?function Gadget(name) = name;G = mirror;var toy = new Gad

14、get(camera);console.log();console.log(toy.hasOwnProperty(name);delete ;console.log();console.log(toy.hasOwnProperty(name);填空题 *_33. What would be the output of the following statements?function deepCopy(p, c) c = c | ;for (var i in p) if (p.hasOwnProperty(i) if (typeof pi = obje

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论