Here's my attempt using Go:
(Keep in mind that I've only been introduced to Go a few days ago so I have absolutely no idea what I'm doing, feel free to improve this)
packagemainimport("bufio""os""fmt""math/rand")funcmain(){// generate and shuffle 0000 - 9999dest:=make([]string,10000)fori,v:=rangerand.Perm(10000){dest[v]=fmt.Sprintf("%04d",i)}// write result to filef,_:=os.Create("result.txt")deferf.Close()w:=bufio.NewWriter(f)for_,line:=rangedest{fmt.Fprintln(w,line)}w.Flush()}
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Here's my attempt using Go:
(Keep in mind that I've only been introduced to Go a few days ago so I have absolutely no idea what I'm doing, feel free to improve this)