Old thread: What are you working on, Jow Forums?
/dpt/ - Daily Programming Thread
first for Ruby
>doll faggotry
Very low T level
>anime
>pedo
>doll
This place gets worse and worse. Next it'll have cat ears or be a little boy or something
You're a literal low energy beta male power bottom faggot. Go to and never come back.
Nvm it does have cat ears already
I am getting the following error when trying to run my python (3) script:
Traceback (most recent call last):
File "TicTacToe.py", line 93, in
main()
File "TicTacToe.py", line 4, in main
startGame()
File "TicTacToe.py", line 13, in startGame
turn(1, tile)
File "TicTacToe.py", line 49, in turn
parse(input, tilex, tiley, tile, inplen)
File "TicTacToe.py", line 70, in parse
x = ord(input[0]) - 64
TypeError: 'builtin_function_or_method' object is not subscriptable
Here is the full code: pastebin.com
input isn't defined, input1 is however
that's literally a catboy doll
I doubt that's a boy
use == please
Not OP here, but at least it isn't that gross common lisp mascot again.
I wonder who thought a gross monster would be a good mascot. Perhaps an anti-fan?
>I wonder who thought a gross monster would be a good mascot.
twitter.com
>nose is a trunk that ends in a thumbed human hand
>Cal Arts giant mouth
>too many eyes (a pair for each level of parens)
>slick green skin, with scaled patches
>four legs which end in four pairs of balls
the nose-hand for the awkward editor interface required to write Lisp that's reasonably formatted
the giant mouth for the community bragging that far exceeds the industrial use of the language
the too many eyes mean nothing - they were added to make it look like an alien
eight testicles is about how many you need to waste on this language, since you know the only value you'll ever get out your investment is in code that you write for your own use
Bjarne is he whomst brings the truth.
C++ is the truth.
lisperati.com
> To most programmers, Lisp seems like an entirely alien language at first- One thing that I think the Lisp community has failed to do is convince other programmers that this strangeness is not an arbitrary obstacle, but a necessary adjustment that imparts great power to programmers that would otherwise be unattainable. The alien Lisp mascot and quirky logo designs are designed to accentuate the awesome (and, to most people, alien) power that Lisp languages have- At the same time, they show how fun Lisp programming tends to be and that Lisp has wide appeal far beyond the stuffy academia it is sometimes wrongly associated with.
Thanks, I'm a retard.
Okay
good job making C++ programmers look crazy
>just going and reading what the lying artist has to say about his work
logo.html doesn't mention 'ballsacks' or 'testicles', so it can't really describe the mascot.
The most powerful programming language is Lisp. If you don't know Lisp (or its variant, Scheme), you don't appreciate what a powerful language is. Once you learn Lisp you will see what is missing in most other languages.
Thinking of copping some Angel Philia bodies. Thoughts?
HOW DO I BECOME A C++ WIZARD I HAVE BEEN READING THE ISO BOOK AND I CANT UNDERSTAND SHIT AM I A BRAINLET?
thank you
Shen vs. Lisp
>Lisp shit
Shen has it
>sequent calculus, giving you the power of a language designer, such as adding your own linear types that work as you want
Shen has it. Lisp doesn't.
>built-in prolog
Shen has it. Lisp doesn't.
>pattern matching
Shen uses it for everything and has enormous readability benefits as a result. Lisp (((has))) pattern-matching but it's the exception, not a real feature of the language that you can expect to find in other people's code. Most Lisp looks like shit because it fails to use pattern-matching.
>pic related
Literally the inventor of Shen. You don't even want to know who invented Lisp (yikes!).
>copping
is this a programming term?
Dolls look like a fun hobby until you realize all the fun is in taking pictures, and it gets boring taking pics of the same dolls in the same clothes so you have to keep buying more accessories all the time.
Actually, do dollfags make their own clothes?
I think I get the appeal now.
I don't know, I'm not a programmer. I just always see doll pics in these threads so I thought you guys liked dolls.
I treat them like my daughters. I carry them with me when I go out. I don't make the clothes because I'm very bad at it.
I thought the appeal was in getting a wife, having kids, and then having to put the dolls away after a kid wakes up in the middle of the night, stumbles into the room with the dolls, and then screams bloody murder after dreaming of the dolls coming awake and saying 'desu desu desu' at h im
> I don't know.
do you even know what it means?
Does the meaning have anything to do with programming?
wtf man I feel like copping *you* right now.
I know what it means in the way that I used it. I have no idea if it also has a separate meaning in programming.
it's hoodrat slang for "obtain", it used to mean you stole it
I'm not here to talk Shen vs. CL but to ask a question:
Pattern matching looks great on paper (literally) but doesn't it necessitate more changes when you refactor?
Please describe your programming background.
>but doesn't it necessitate more changes when you refactor?
why would it?
Just copy a line down/up and change some variables.
i have been using C++ for ~2 years while studying at uni
if u ask me to solve some algorithms or make some dummy projects i can do it
but the moment you talk about the laws of C++ my brain just fart
am i a pajeet????? aaaaaaaaaaaaaaaaaaaaaaAAAAAAAAAAAAAA
have kids, user. you'd be a great parent.
Do you not have to do this in each place where you pattern match a type?
Lisp is the most powerful programming language.
very rarely would/should you pattern match on prims.
maybe types with Just a | Nothing is a common pattern though
working with rails
studying go
programming C
>learning js
>IIFE
>arrow functions
>maps
>async
>bind, call, apply
seems pretty cool
Unironically learn Lisp.
If one source doesn't make sense, find another.
Books are good sources because they have editors. Their job is to make you understand.
Oh, I see. Do you also use multimethods in Shen? I tried googling but finding info about Shen is near impossible thanks to its name. I wish they would rename it.
books only covers the surface of C++ tho, they tend to never actually touch the underlying regulations and the committee wizardry
>I tried searching the entire web
>with the worst search engine
just go to shenlanguage.org
'googling' (*gag*) only seems to work for popular languages, but even then if the language changes rapidly you'll start getting out of date 2012 stackoverflow answers for shit. Just learn and then go to authoritative sources. Search engines were never really a superpower and Google was always shit. I realized this most painfully once I got an admin job, and realized that answers from an admin perspective were a needle in the planet-sized haystack of answers from a user perspective. "my server is down what's wrong. Oh I fixed it--the drive was out of space." HOW VERY USEFUL.
>Do you also use multimethods in Shen
no. Can't even have two different functions that only vary by arity.
Oh right. i should probably read reply chains properly.
Yeah, pattern matching on dep types is a bit different and you would do it on prims a lot more often, because that's kind of the point of dep types. Refactoring those isn't more painful, and FP refactoring is a lot less scary than imperative/OOP refactoring (actually less in Idris due to some neat compiler help you can invoke to skeleton define, do menial case-splits, and lift things to top-level definitions with just a few keybinds in the right editors). Not sure about Shen, but since it has dep types, multi-methods aren't needed because they're an inferior version.
very cute doll
>Pattern matching looks great on paper (literally) but doesn't it necessitate more changes when you refactor?
I've no idea why you would even think so, man. But a big advantage of pattern matching is that if you always have exhaustive matches, then changing your data types causes the compiler to tell you about every single no-longer-exhaustive match that you have to update. This makes this sort of refactoring easier and faster, to the point that I wouldn't even care if it technically resulted in more *keypresses*. The point is I don't have to search through the code to find places where I have to handle a new variant. That hard, faulty process is largely removed.
c++ people doesnt understand rust strict and tyrannical compiler isn't forcing you to do useless stuff, its trying to tell you your program is fucking broken, buggy and shit so go fix it
its not useless work unlike dealing with the quirks of backward compatible C++20
What is a better search engine? I never had a problem looking up clojure info (thanks to its unique name).
Make a meme file format that works like a block chain and a snapshot of each change made to it (including if it's downloaded and amount of downloads from origin)
Need architect, 2 senior devs and some lackeys.
ddg's good for weaning yourself off of Google as you can add !g to any query to pull up the Google results instead, which you can confirm to not be useful.
Hi everyone, I'm making a Jow Forums clone and I was wondering what is the best way to sort boards? I need a method to prune and promote good threads. Reddit does this through their upvote system, but how could I implement it for a Jow Forums clone? The same basic mechanics would be there, such as thread pruning, but I need a better way to sort than to sort by last post and bump limit.
Do you guys have any suggestions?
Here's the article that describes reddit's algorithm
medium.com
any good resources to learn ocaml on youtube?
anything you try to implement will be abused.
only bumps work well
>I'm making a Jow Forums clone
bad start.
>Reddit
>upvote
>reddit's
your pic is now related. Where's the gore follow-up?
just get mods. I know that hotpockets are very expensive and that 2/7 days isn't a lot of coverage, but the alternative to mods is tyranny, just like you find on reddit. And that tyranny doesn't work very well with anonymity.
Is the gore follow-up for when you reveal your project requires namefaggging?
thanks
include a pic to be noticed
Go get an image classifier. If the image contains anime, it's a good post and bumps the thread. If it doesn't, it's a bad post and the poster gets a temporary ban.
What do you guys think about using comments as a pseudo upvote? Another idea is to monitor user interaction like how long they take to read a thread and then use that as a pseudo upvote, but I think that might be abused by people who leave their tabs on...
These ideas keep getting gayer.
Keep going, I want to see your limit.
Pictures of crustacean devastation also prove the post is not a shill
>have to use java for my CS classes
>need to multiply a string of whitespace for a project
>it's a pain in the ass and I don't think I'm allowed to even do it according to the project rules
Is this what people are on about when they complain about this language?
Learn Lisp.
>val .x = 123 immutable declaration and assignment
>var .y = 123 mutable declaration and assignment
such a well designed language. it only took me 15 seconds to realize that there was any difference at all in the code
>I can't read
Not him but val/var are shit anyway.
optional implicit type inference with immutable by default is a far better option.
>all design failure is actually user failure
it's also horribly racist.
Many Chinese and Japanese speakers have trouble differentiating their 'r's and their 'l's. How are they supposed to talk about this code?
The only language to have a mutt keyword.
struct American {
polish: u8,
italian: u8,
mexican: u8,
nigger: u8
}
fn main() {
let mut pablo_smith = American{polish: 10, italian: 15, mexican: 50, nigger: 25};
}
You need to put it in an unsafe block.
very different words would be acceptable as well.
let x = 1 vs. var x = 2
Meanwhile, Perl has 'my $x', 'our $x', 'local $x', and this is only for scoping differences. Mnemonic, impossible to confuse visually or audibly, and yet terse and useful. This is why Perl is a better language for newbies and a more readable language than, to pick a completely random sack of shit, Python, where you can't distinguish between variable initialization and assignment, and where your options are 'x = 4' for fucked up non-lexical scope vs. 'global x' for not-actually-global-and-also-much-slower-to-mutate-wtf scope.
FURTHER PROOF
The ATS, which is famously hard to read, has this exact 'val'/'var' distinction.
You fa/g/s got some kinda problem with dolls?
Leggo my bro!
What's faster than lua for embedded scripting?
Not even vaguely programming related at this point
>scripting
why
Program this
>embedded scripting
you mean, "what's an extension language that's faster than Lua?"
Lua's probably it, chief. Tcl might compete. Guile is probably a lot slower.
>embedded scripting
you mean, "what's a fast scripting language that I can use on embedded platforms?"
Forth.
Program a girlfriend
Dynamically loaded ELF objects, preferably written in C.
Girlfriend gf = new Girlfriend(Male);
Where do I get one of those dolls?
She looks like a massive masochist
Type mismatch.
Expected type 'Female'
Got type 'Male'
Faster in what way? Execution speed? Development speed? What are you embedding it in? What do you intend to use it for?
link the API
assert girl(male)
It's a catgirl you fucking degenerate.
That smile just visible through the sights is so cute!
Program sex
ECL
VLC on Lubuntu isn't closing properly, and the way I found to get it to close is:
ps -e | grep -i VLC
(returns value)
kill -9 (value)
I'm sure there's a quick and easy way to throw this into a shell script, but I only python and a little web-based stuff. Could anyone help me out real quick?
pkill -9 VLC basically does all of those steps for you.
pgrep also exists, which is similar to the first line.
That doesn't seem to be working for me. It stayed open in the status notifier, which prevents it from opening any new files.
Oh right, it's probably because of the case sensitivity.
pkill -i -9 VLC
But you should probably try and find out why it's fucking up in the first place. SIGKILL (-9 argument) is a worst-case scenario way to try and kill a process.
I feel like Go is one of the least criticized languages here. Is Jow Forums owned by jewgle?
Go is webdev shit. Webdev shit is not allowed here.
You haven't browsed much then
Go is about as much webshit as C++ is. It's a backend language you fucking idiot.
The only difference is Go is shit.
>it's another I've been here 5 minutes, but already an authority on the entire thread
we shitposted go so much it got boring