Skip to main content
deleted 8 characters in body
Source Link
Zombo
  • 1
  • 10

Go, 268260 bytes

Most answers on this page are now wrong, as Google no longer accepts Firefox/8 as a valid User-Agent:

package main import(."io" h"net."net/http" r"regexp"."regexp") func main(){e,_:=h.NewRequest=NewRequest("GET","https://www.google.com/search?q=codegolf",nil) e.Header.Set("User-Agent","Firefox/51") s,_:=new(h.Client).Do(e) b,_:=io.ReadAll=ReadAll(s.Body) print(string(r.MustCompile(`About \S+ results`).Find(b)))} 

Go, 268 bytes

Most answers on this page are now wrong, as Google no longer accepts Firefox/8 as a valid User-Agent:

package main import("io" h"net/http" r"regexp") func main(){e,_:=h.NewRequest("GET","https://www.google.com/search?q=codegolf",nil) e.Header.Set("User-Agent","Firefox/51") s,_:=new(h.Client).Do(e) b,_:=io.ReadAll(s.Body) print(string(r.MustCompile(`About \S+ results`).Find(b)))} 

Go, 260 bytes

Most answers on this page are now wrong, as Google no longer accepts Firefox/8 as a valid User-Agent:

package main import(."io" ."net/http" ."regexp") func main(){e,_:=NewRequest("GET","https://www.google.com/search?q=codegolf",nil) e.Header.Set("User-Agent","Firefox/51") s,_:=new(Client).Do(e) b,_:=ReadAll(s.Body) print(string(MustCompile(`About \S+ results`).Find(b)))} 
Source Link
Zombo
  • 1
  • 10

Go, 268 bytes

Most answers on this page are now wrong, as Google no longer accepts Firefox/8 as a valid User-Agent:

package main import("io" h"net/http" r"regexp") func main(){e,_:=h.NewRequest("GET","https://www.google.com/search?q=codegolf",nil) e.Header.Set("User-Agent","Firefox/51") s,_:=new(h.Client).Do(e) b,_:=io.ReadAll(s.Body) print(string(r.MustCompile(`About \S+ results`).Find(b)))}