Commit b8b55a55 authored by Ahmad Nemati's avatar Ahmad Nemati

git pull

parent 39cee46a
...@@ -123,7 +123,8 @@ async function run() ...@@ -123,7 +123,8 @@ async function run()
} }
arrNew = _.orderBy(arrNew, ['sum']) arrNew = _.orderBy(arrNew, ['sum'])
console.log(arrNew) console.log(arrNew[0])
// console.log(arrNew)
for (let i=0;i<arr.length;i++) for (let i=0;i<arr.length;i++)
addDate(arr[i]) addDate(arr[i])
...@@ -147,9 +148,10 @@ async function run() ...@@ -147,9 +148,10 @@ async function run()
} }
arrDate = _.orderBy(arrDate, ['sum']) arrDate = _.orderBy(arrDate, ['sum'])
// console.log(dates) console.log(arrDate)
// console.log('Balance ->',balance) console.log('Balance ->',balance-lastBalance)
// console.log('Worth ->',arrNew[0]) let worth = (balance - lastBalance) / (arrDate[0].sum)
console.log('Worth ->',worth)
......
...@@ -35,8 +35,7 @@ async function init() { ...@@ -35,8 +35,7 @@ async function init() {
} catch (e) { } catch (e) {
} }
let rand=randomInt(0,files.length) coms = await fs.readFileSync('t.json', 'utf8');
coms = await fs.readFileSync(files[rand], 'utf8');
let bad = await fs.readFileSync('bad.txt', 'utf8'); let bad = await fs.readFileSync('bad.txt', 'utf8');
bad = JSON.parse(bad) bad = JSON.parse(bad)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment