Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- console.time('program');
- const fs = require('fs');
- const filePath = "./processhackerfile.txt";
- const hackStringsPath = "./hackstrings.txt";
- var hackStrings = fs.readFileSync(hackStringsPath).toString().split("\n");
- console.log(hackStrings.length);
- var file = fs.readFileSync(filePath).toString();
- for(i in hackStrings){
- var regex = new RegExp(hackStrings[i].toString(), 'i');
- var stringSearch = file.match(regex);
- if(stringSearch != null){
- console.log(`Cheat found, string name: ${stringSearch}`);
- } else {
- console.log('Cheat not found');
- }
- }
- console.timeEnd('program');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement