Skip to content

Commit 194b221

Browse files
committed
lecture 71 done
1 parent 7c15dc1 commit 194b221

3 files changed

Lines changed: 18 additions & 0 deletions

File tree

File_handling/data.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Hello World ==> 123456

File_handling/fs_file.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/*
2+
Lecture # 71
3+
Topic : fs Module and Read File in JavaScript
4+
5+
fs Module:
6+
fs module is used to work with files in Node.js.
7+
8+
const fs = require("fs");
9+
10+
Read File:
11+
Reading a file means getting data from a file.
12+
*/

File_handling/read.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
const fs = require("fs");
2+
3+
fs.readFile("File_handling/data.txt", "utf8", (err, data) => {
4+
console.log(data);
5+
})

0 commit comments

Comments
 (0)