Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit f6b1a0f

Browse files
Question-Answer 89-90
1 parent fa7ea77 commit f6b1a0f

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

‎README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,8 @@
9393
| 86 | [In how many ways we can make an object non-extensible](#86-in-how-many-ways-we-can-make-an-object-non-extensible) |
9494
| 87 | [What is object.freeze method](#87-what-is-objectfreeze-method) |
9595
| 88 | [What is object.seal method](#88-what-is-objectseal-method) |
96+
| 89 | [How can you determine if JavaScript is disabled on a page](#89-how-can-you-determine-if-javascript-is-disabled-on-a-page) |
97+
| 90 | [How can you compare two date objects](#90-how-can-you-compare-two-date-objects) |
9698

9799
### 1. What is JavaScript
98100
* JavaScript is a scripting language used to create dynamic and interactive websites. It is supported by all major web browsers.
@@ -1292,6 +1294,29 @@ console.log(obj); // output ========> { property1: "new value", property2: "val
12921294
12931295
**[:top: Scroll to Top](#javascript-interview-questions)**
12941296
1297+
### 89. How can you determine if JavaScript is disabled on a page
1298+
```<noscript>``` tag is used to determine if JavaScript is disabled on a page. It provides alternative content that should be displayed when JavaScript is not supported or disabled in the user's browser.
1299+
```js
1300+
<noscript>
1301+
<p>JavaScript is disabled in your browser.</p>
1302+
</noscript>
1303+
<script>
1304+
console.log("JavaScript is enabled on page");
1305+
</script>
1306+
```
1307+
**[:top: Scroll to Top](#javascript-interview-questions)**
1308+
1309+
### 90. How can you compare two date objects
1310+
getTime() method is used to compare two date objects.
1311+
```js
1312+
let date1 = new Date();
1313+
let date2 = new Date(date1);
1314+
console.log(date1.getTime() < date2.getTime()); // output ========> false
1315+
console.log(date1.getTime() > date2.getTime()); // output ========> false
1316+
console.log(date1.getTime() === date2.getTime()); // output ========> true
1317+
```
1318+
**[:top: Scroll to Top](#javascript-interview-questions)**
1319+
12951320
## Output Based Questions
12961321
12971322
**1. What will be the output**

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /