1,209 reputation
61540
bio website
location
age
visits member for 3 years, 5 months
seen Oct 14 at 17:32

I'm the author of a natural language programming system called EngScript.

Some of my favorite software projects are:

I have written some useful macros in sweet.js:

//for repeating if statements
macro ifs{
    rule{
        {$($x {$y...}) ...}
    } => {

        $(if($x){
            $y...
        }) ...
    }
}

//a concise way to define several different functions
macro manyFuncs{
    rule{{$($x ($y...) {$z...}) ...}
    } => {
        $(function $x($y...){
            $z...
        }) ...
    }
}

ifs {
    a{
        b
    }
    c{
        d
    }
}

manyFuncs{
    fullName(firstName, lastName) {
        return firstName + lastName;
    }
    squared(a){
        return a*a;
    }
}

Right now, I'm searching for a parser that can handle ambiguous grammars.

In theory, it would also be possible to create a very concise programming language with implicitly defined parameters:

isDivisibleBy: (foo % bar) == 0
//This is a function with 2 parameters: foo and bar.

isEven: isDivisibleBy(foo, 2)

isOdd: !isEven(param1)

firstCharacter: theString[0]

lastCharacter: theString[theString.length - 1]

firstNCharacters: theString[0:end]

firstCharacterIsLastCharacter: firstCharacter(stringParameter) == lastCharacter(stringParameter)

printEach: for current in anArray{ print current }

http://rosettacode.org/ is one of the most comprehensive programming language references I've ever found.

Optionally-typed programming languages are really awesome: they combine the type safety of languages like Java with the conciseness of languages like Python.

Some cool things that I've made:

Someday, I hope it will be possible to create a programming language that mixes code from different languages into a single file, like this:

Python {
    def foo():
        return "foo"
}
Ruby {
    def bar
        return foo + " was called from Python."
    end
}

Aug
3
comment How can I delete all web history that matches a specific query in Google Chrome
Further information is here: superuser.com/a/747816/85129
Jan
6
comment Is it possible to work offline in Google Chrome (as in Firefox?)
@Cawas Are there any future plans for an "offline mode" as a feature of Google Chrome?
Nov
20
comment Unbalanced Parenthesis in a for loop in batch
This question might be more relevant on Stack Overflow, since it's a programming question.
Sep
30
comment Automatically change time based on current location
Is TimeTraveller compatible with Windows 8?
Sep
13
comment Windows Console in Explorer Context Menu
The link in this answer appears to be broken now. :/
Jun
15
comment How can I keep track of the programs that have been used to edit a file?
I'm still confused. What do you mean by "in the default saved all the events occurring in the system"?
Jun
15
comment How can I keep track of the programs that have been used to edit a file?
Also, which of these three tools would be able to keep track of the programs that have edited a file? Will I need to choose one of these three programs, or will I need to use all of them at the same time?
Jun
15
comment How can I keep track of the programs that have been used to edit a file?
What do you mean by "create filters that file sizes would not be very large"?
Jun
10
comment Is there a Windows keyboard shortcut to combine accent marks with other characters?
Yes, it's an en_US keyboard layout.
Jun
10
comment Is there a Windows keyboard shortcut to combine accent marks with other characters?
@SBI This is what happens: ~n. The characters don't combine automatically when I type them like this.
May
24
comment How can I find the terminal command to run a specific program in Windows 7?
@Ramhound I'm asking whether it's possible to find the command to run a program from the icon's context menu. I don't see anything confusing about the question. Is there anything that I need to explain more clearly?
May
7
comment pdf - Get current page number in Google Chrome
@VianEsterhuizen It actually doesn't answer the question entirely - pressing the "Print" button simply jumps to the first page of the document, instead of jumping to the currently viewed page. Due to this bug, it seems that there's no easy way to obtain the current page number in a multi-page document.
Apr
12
comment Remove auto-complete field entries in Google Chrome
Will this delete all autofill entries from Chrome, or will it only delete some of them? (Also, is there any way to delete all autofill text from all search boxes in Chrome)?
Apr
12
comment How to remove one or all auto-complete text entries in Chrome?
Will this delete all autocomplete entries on all sites, or will it only delete some of them?
Apr
10
comment Block offensive images from all sites in Google Chrome
I wouldn't want to manually create a list of every gory/violent/disturbing image that I found on Wikipedia - some kind of automated filter would be better.
Apr
10
comment Block offensive images from all sites in Google Chrome
@Insilico Which human element are you referring to, specifically? This phrase seems ambiguous.
Apr
10
comment Block offensive images from all sites in Google Chrome
Do any of these parental control programs allow blocking of Safesearch-filtered images (or at least a community-edited image filter)?
Apr
10
comment Block offensive images from all sites in Google Chrome
@Insilico Yes, the Internet does contain some imagery that many people find disturbing or violent. That's why I'm wondering whether it's possible to block all images that are ordinarily filtered by Google Image Search. (Also, I'm not concerned about whether or not Google's standard for offensiveness matches mine - I just want to use Google's safesearch filter for images on all sites.)
Mar
28
comment Find recently created folders in Windows
Should <Location_to_Search> be replaced with C:\Program Files, or should it be replaced with "C:\Program Files"? When I replace it with either of these and run the program with PowerShell, I see an error message and the window closes immediately (so that I can't even see the output).
Mar
28
comment Find recently created folders in Windows
How can I run this code?