require('protos.js');
var users = [];
users.load('users.txt');
if (!users.has('mike')) {
users.push('mike')
users.save('users.txt')
}
if ('mike'.in(users)) {
'mike is here'.log()
'John'.appendFile('users.txt')
}
var str = 'test';
str.log();
str.save('file.txt');
str.save('file.txt', function() {
'async saved!'.log();
});
var str = ''.load('data.txt');
['a','b','c','d'].cut(1,3);
['a','b','c','d'].cut(1,-1);
var el = 'hello'.cut(1,3);
var lo = 'hello'.cut(3,-1);
var num = '3'.toInt();
var struct = {}.load('file.json');
struct.save('file.json');
struct.save('file.json', function() {
'saved'.log();
});
struct.dir()
'hello'.compare('hell')
'hello'.compare('hello')
'hello'.compare('abcd')
var hash = 'hello'.fuzzyHash();
objects.call('method',[params]);
> ['cats','dogs','birds'].choice()
'dogs'
> [3, 1, 2, 3].unique()
[ 3, 1, 2 ]