-  [WT]  [PS]  [Home] [Manage]

  1.   (new thread)
  2. [ No File]
  3. (for post and file deletion)
/pr/ - Programming
  • Supported file types are: C, CSS, DOC, DOCX, GIF, H, JAVA, JPG, PDF, PNG, SVG, SWF, TXT, WEBM
  • Maximum file size allowed is 10000 KB.
  • Images greater than 200x200 pixels will be thumbnailed.
  • Currently 488 unique user posts. View catalog

  • Blotter updated: 2011-01-12 Show/Hide Show All

There's a new /777/ up, it's /selfhelp/ - You're Pathetic, We're Pathetic, We Can Do This! Check it out. Suggest new /777/s here.

Movies & TV 24/7 via Channel7: Web Player, .m3u file. Music via Radio7: Web Player, .m3u file.

WebM is now available sitewide! Please check this thread for more info.

I Before E Except After C Algorithm(Python) Neckbearded Basement Dweller 13/12/28(Sat)23:47 No. 4261 [Reply]

File 138827083071.jpg - (68.80KB , 620x880 , wrong ie.jpg )

So I was challenged today to prove this graphic I shared on Facebook and ended up disproving it by a lot with a simple python program. As with any good scientist, I would like some people to:
1. Try it with different (>100000 words) wordlists to see if my results hold up that when "I" and "E" are both in a word the I before E rule is followed roughly 75% of the time.
2. Make sure the algorithm is correct.
SOURCE: https://docs.google.com/viewer?a=v&pid=sites&srcid=ZGVmYXVsdGRvbWFpbnxoYXNlcmVubGFuZXNoZXJzdHVkaW9zfGd4OjUyM2YxYzU0YjZmYWE2N2U

4 posts omitted. Click Reply to view.
Neckbearded Basement Dweller 14/04/20(Sun)15:05 No. 4412

We almost wrote the same pieces of code.

(use (srfi 1 13)) (let ((words (string-split (with-input-from-file "en_US.txt" read-string)))) (map (lambda (pattern) (cons pattern (fold (lambda (h t) (if (string-contains-ci h pattern) (add1 t) t)) 0 words))) '("ei" "ie" "cei" "cie")))

Neckbearded Basement Dweller 14/08/09(Sat)06:53 No. 4548

So the 'except after C' part IS bullshit?

Neckbearded Basement Dweller 14/12/24(Wed)03:23 No. 4652

>>4548 nah because the wordlist must consist only of words where ie/ei should actually be "ee"

Neckbearded Basement Dweller 14/11/20(Thu)02:39 No. 4621 [Reply]

File 141644754369.jpg - (137.40KB , 1200x1200 , 1416435128698.jpg )


>The Male Programmer Privilege Checklist

Neckbearded Basement Dweller 14/11/22(Sat)16:02 No. 4622

Not nearly as funny as the C+= documentation. They still get points for trying.

Neckbearded Basement Dweller 14/11/26(Wed)04:32 No. 4624

File 141697275325.png - (240.81KB , 1078x871 , linux_for_niggers.png )

Debian, you used to be such a great distro but look at you now... where did it all go wrong? I know you're still bummed for losing that popularity contest to your cousin Ubuntu but you need to get your shit together man.

Neckbearded Basement Dweller 14/12/24(Wed)03:10 No. 4651

probably a false flag to disrupt devs with shitty off-topic discussions.
like the bot/spammer mentioned here:

Neckbearded Basement Dweller 14/02/25(Tue)21:38 No. 4333 [Reply]

File 139336069175.png - (42.26KB , 800x444 , vi-emacs-final.png )

So, programming on GNU/Linux:

Which is best? An IDE, Vim, or Emacs? (Instead of shitposting or flamewarring, you have to give a legitimate reason for your answer and why you like it better than the other options)

21 posts and 3 images omitted. Click Reply to view.
Neckbearded Basement Dweller 14/06/18(Wed)06:36 No. 4480

I use nano and gedit. Vim is too complicated for my needs (basic C++ and other things).

Neckbearded Basement Dweller 14/12/15(Mon)23:23 No. 4644

It's all preference; you can use any text editor with multiple terminals for compiling/running, or you can use a fullblown IDE. If you want something more GUI-oriented, try Geany.

Neckbearded Basement Dweller 14/12/22(Mon)18:32 No. 4649

Emacs for programming and vi for configs and quick edits.

Emacs bindings are through out Linux/unix so you get a bonus extra skill.

The down side is emacs isn't a default install on most systems and is large. Dev is also run by RMS personal army.

Org mode is gdlk.

Both editors have great plugin selection, emacs is elisp which is less ghetto

Either editor is great though and I suggest you try both and learn one really well and be proficent in the other. Fuck nano/pico.

Both editors have parity features in curses and GUI mode so you can edit over SSH

Java Beginner Lamoa 14/08/06(Wed)06:17 No. 4541 [Reply]

File 140729862373.jpg - (72.60KB , 500x500 , Front.jpg )

Hi guys, I just discovered /pr/ and I think this is really great. Im a first year I.T. student,and right now we're at Netbeans Java in our programming class. Im really a beginner and before taking college I have no idea about programming but I really like it.
Can you give any tips and advice on how to be a great programmer and how can I improve my logic skills.

1 post omitted. Click Reply to view.
Neckbearded Basement Dweller 14/08/18(Mon)03:42 No. 4566


I was in almost exactly the same position as you, OP. Barely finished my BSc.

Now I'm finally going all into it.

Not+A+Douche 14/11/15(Sat)19:15 No. 4619

Just caught my wife still using that program. It has been 2 years

Neckbearded Basement Dweller 14/12/08(Mon)21:34 No. 4638

Pratice. Pratice. Pratice.

Getting items from website to app Neckbearded Basement Dweller 14/12/08(Mon)19:08 No. 4637 [Reply]

File 141806210734.jpg - (8.83KB , 843x403 , 164204_10151467305537900_4299705_n.jpg )

Is this a good way to get stuff from a website into your app?

Document doc = Jsoup.parse(html);
List<String> titles = new ArrayList<>();

for( Element element : doc.select("div[class=title]") )

Neckbearded Basement Dweller 13/01/31(Thu)20:18 No. 3387 [Reply] [Last 50 posts]

File 135965991476.png - (4.10KB , 640x320 , Girls-Who-Code.png )

What do you anons think about those people who are trying to increase the number female programmers in the world?

68 posts and 7 images omitted. Click Reply to view.
Neckbearded Basement Dweller 14/10/18(Sat)07:49 No. 4606

File 141361136013.jpg - (98.89KB , 800x640 , average_archlinux_user.jpg )

>One point I do give them(although not on the same train of thought) is the toxic culture of the tech community, especially OSS.
Important projects are tired of dealing with idiots, but if you try to contribute to a small project you will be treated nicely. If for no other reason, because they really need the help.

>who do you see in CS classes? Neckbeards and kids with autism who usually have delusional beliefs, whether it be worshipping anything with a vagina, or immediately discounting anything with a vagina.
>On top of that is already a deep sense of elitism.
Pot, meet kettle.

Nattajerk 14/10/20(Mon)22:42 No. 4607

when I was in CS there were a few weirdos but for the mostpart it was your standard sitcom lineup. a hot asian girl, the token black guy, the token gay guy. the older "restarting my career" 40 year old. and a bunch of teenagers who got a free ride into post secondary learning.

Neckbearded Basement Dweller 14/11/25(Tue)06:03 No. 4623

I feel whoever is the most qualified - in any field - should have the job, regardless of their sex. However, if there are a male and a female applying for a job, both of which are qualified equally, the decision should be made which one to hire depending on how they would interact with the other employees.

Neckbearded Basement Dweller 14/11/09(Sun)03:05 No. 4616 [Reply]

File 141549870368.png - (41.13KB , 300x300 , unnamed.png )

I'm trying to get into doing contracted work for people seeking Wordpress themes, what is a typical request that clients will ask me for?

I'm considering in throwing together a small game in JavaScript and having it interface with MySQL and other Wordpress technologies to show people that I am capable of putting together Wordpress themes that can perform a wide range of functions with HTML5/AJAX/CSS/MySQL/PHP.

Sorry if it sounds like I have no idea what I'm doing, but that's sort of the reason why I'm asking this question in the first place.

feh a shit nigger 14/08/28(Thu)01:08 No. 4569 [Reply]

File 140918089256.png - (695.93KB , 1366x768 , 2014-08-27-170529_1366x768_scrot.png )

why the fuck does feh do this?
any better alternatives other than qiv or sxiv?

The problem might be an extension to my non tiling wm, which gives it basic twm abilities. Anyways, in the extension, I set it to get rid of window borders for all windows, but even if I command "feh -x file.jpg", it will still do this.

3 posts omitted. Click Reply to view.
nigger 14/08/29(Fri)20:11 No. 4574

File 140933589730.jpg - (62.06KB , 640x483 , sleeping pizza.jpg )


Neckbearded Basement Dweller 14/08/30(Sat)05:44 No. 4575

It works for me with feh v2.12-1.

Neckbearded Basement Dweller 14/11/05(Wed)04:06 No. 4613

Try, 'feh -. file.jpg'

need help with c# Neckbearded Basement Dweller 14/11/02(Sun)20:47 No. 4610 [Reply]

File 14149576639.png - (6.31KB , 571x349 , lameapp.png )

hy pr
i am stuck with one windows form app i am trying to do for my practice in c#
i need an app which has 3 buttons and one textbox ( pic related )
mechanism is very easy but i kinda cant solve it to work
Plan is to make an app which does:
-generates random number ( 0,1 or 2)
-writes that number in read only textbox

waits for button click

-button click sets user input variable to a specified value .every button has its own value ( 0,1 or 2)
-sends that value to main code

checks if randomnumb = userinput
raises numberofcorrect by one if its correct
Message too long. Click here to view the full text.

JSON loading Neckbearded Basement Dweller 14/10/13(Mon)23:13 No. 4602 [Reply]

File 14132348201.jpg - (305.67KB , 612x1008 , we_can_do_it__portal_2_propaganda_poster_by_aelice.jpg )

I want to use multiple jsons (one for every lang) for ex: the english one:
"key1" : "value 1",
"mainMenuText" : "Main Menu",
"thisIsAnArray" : [
"ThisIsASubObject": {
"SubKey1": "SubValue1"

Message too long. Click here to view the full text.

Neckbearded Basement Dweller 14/10/14(Tue)23:38 No. 4604

While I've never used JSON I've never seen it described quite like you have it there.

perhaps something more like;

would make more sense, as I am pretty sure everything has to be wrapped in curly braces. as far as I know, JSON uses nearly the exact same syntax for defining an object in Javascript, so that may be your problem.

That guy who replies to posts eons later 14/10/31(Fri)15:14 No. 4609

Make an array of objects instead.

Delete post []
Report post