From c873a033fd176c18016539111de06c664ca60af3 Mon Sep 17 00:00:00 2001 From: vivek jain Date: Sat, 6 Apr 2019 13:54:23 +0530 Subject: [PATCH 1/2] Array of 5 file path read using only readFile in sync only using Callbacks --- array5.js | 26 +++++++++++++++++++ readme.txt | 0 txtfiles/0.txt | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++ txtfiles/1.txt | 7 ++++++ txtfiles/2.txt | 30 ++++++++++++++++++++++ txtfiles/3.txt | 5 ++++ txtfiles/4.txt | 36 ++++++++++++++++++++++++++ 7 files changed, 172 insertions(+) create mode 100644 array5.js delete mode 100644 readme.txt create mode 100644 txtfiles/0.txt create mode 100644 txtfiles/1.txt create mode 100644 txtfiles/2.txt create mode 100644 txtfiles/3.txt create mode 100644 txtfiles/4.txt diff --git a/array5.js b/array5.js new file mode 100644 index 0000000..6fd7edd --- /dev/null +++ b/array5.js @@ -0,0 +1,26 @@ +const fs = require('fs'); +let j=0; +console.log("===================================="); +function f1(arr) { + if(j Date: Sat, 6 Apr 2019 14:17:23 +0530 Subject: [PATCH 2/2] corrct Indentation --- array5.js | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/array5.js b/array5.js index 6fd7edd..e29f5aa 100644 --- a/array5.js +++ b/array5.js @@ -1,26 +1,23 @@ const fs = require('fs'); -let j=0; +let j = 0; console.log("===================================="); function f1(arr) { - if(j