Open the browser to http://codegolf.stackexchange.com
Oration, 41 bytes
Not winning, but sure was fun. As of right now, I'm only 1 bytee behind python!
I need webbrowser
Now open "http:ppcg.ga"
Explanation:
I need
compiles to import $1
with webbrowser
being the module.
Now
runs the following command from the module as module.command
with the arguments of anything following.
So this compiles to:
#!/usr/bin/env python3
import webbrowser
webbrowser.open("http:ppcg.ga")
I do end up needing the http:
part though, and it can't be shortened.
Batch, 17 bytes
Saved 3 bytes thanks to Mego.
start www.ppcg.ga
This will open in your default browser if you run it from the windows command line.
I think it'll work in Powershell too, but I'm not sure.
GNU Emacs, 29 27 14 bytes
(eww"ppcg.ga")
EWW is a browser inside Emacs. The browse-web
function is an alias for eww
, and so that makes eww
the default browser in Emacs:
Your job is to open a browser window of the default browser to http://codegolf.stackexchange.com.
Thanks to @CoolestVeto, @Jonathan Leech-Pepin and @zyabin101.