/dpt/ - Daily Programming Thread

Old thread: What are you working on, Jow Forums?

Attached: Chihiro_Fujisaki_Illustration.png (962x962, 948K)

Other urls found in this thread:

pastebin.com/uNgd8RJ1
paste.debian.net/hidden/60c02eec/
2018.stateofjs.com/javascript-flavors/overview/
wikemacs.org/wiki/Paredit-mode
twitter.com/SFWRedditVideos

>yuno chain is broken
RIPIP

It had stop some time, it was fun while it lasted.

I'm writing a simple bytecode interpreter in C just to see if I understand the basics of assembly. I will post the header in a thread when I'm happy with it so you guys can fuck around and tell me why I'm retarded.

It uses my own 'architecture' for the sake of simplicity

well i mean chihiro is basically yuno right

Attached: indistinguishable.png (676x548, 385K)

i am also doing this
have fun user!

Lisp is the most powerful programming language.

there's no such thing as a most powerful programming language because there are many languages that can do anything the host machine can do.

there is however such a thing as a least powerful programming language

the least powerful programming language is the programming language consisting of everything you ever type when you buy a keyboard but forget to buy a computer to go with it

yuno is the cutest

Attached: 1461916400967.jpg (1024x768, 121K)

Making scalable vector graphics for my program's images.

yuno = a[shit];

JavaScript rocks!

Attached: js-rocks.png (1000x494, 369K)

>turn power off by accident
>android studio is fucking broken AGAIN

Attached: 1531577929373.jpg (194x259, 4K)

holy shit i want to shoot myself in the head rn
what was happening is that grep is fucking retarded and was treating the chinese tawaianese african korean characters as if they were binary, so instead of outputting them it just outputted "Binary file (standard input)", so all I had to do was add "-a".
fuck grep developers for not respecting others people culture and language am i rite

Don't worry, just:
- gradle sync
- clean project
- invalidate caches
- re-import project

>he blames his retardation on others

>my retardation
friend I wasn't the one who was treating a different alphabet as fucking binary

Most people know wtf they're doing. Just saying.

shut up please

That's the great thing about build scripts. Just delete everything but src and re-build. I used to have so many problems with IntelliJ Idea before I learned to not put any of the package files in the version control and just rebuild everything when I switch to a new branch.

>stop making me feel stupid!
kek, the epitome of autism.

That's impractical for the projects I work on. Indexing alone already takes minutes.

I just realized that C and Unix are almost 50

I admire your attitude

>oh boy time to program
>end up testing editors instead

Attached: 1465847954964.jpg (161x110, 6K)

just use vs code.

i literally use gedit

I would but it bothers my autism because I'm on fedora and the dnf repo is often lagging behind and the flatpak is sandboxed so it supposedly introduces issues

Attached: 1467544552285.jpg (503x462, 129K)

>fedora
install arch.
problem solved.

no

why developing for android is so shit

but fedora is for dweebs.

I don't like Javascript, because I don't like functional programming

fedora is for esteemed gentlemen and anime girls

Attached: 1424558244788.png (506x538, 216K)

because you're not using Kotlin

Use emacs, it solved that problem for me.

honestly, what strides have been made in computer science
what has been discovered, what has changed since 50 years ago
maybe machine learning has undergone some development, kinda, but it's still garbo
where the fuck are the lisp computers, general ai, quantum computing, p != np proof
where are my compilers, interpreters and languages that allow me to prove correctness of my programs without having to test inputs

>le typed lambda calculus research
lol, like that's gonna do anything

>using fedora
>vscode needs compiling

Fedora is shit, and is for faggots.

I just downloaded that mastering emacs book so I will
no
elaborate

>where are my compilers, interpreters and languages that allow me to prove correctness of my programs without having to test inputs
Idris, Agda, Coq and such have been around for a bit. F* if you want extreme verification.

You don't even need the full text mode, I just find that having it open and having my terminal right there helps me to focus.

Fedora is for faggots, and you can just download and run vscode. Also, use vim.

it's certainly nice as I've used it before but I need some additional modes and plugins and getting that or customizing in general seems too intimidating
no
>you can just download and run vscode
but it's not that OSS version

That's fine. JS is a multiparadigm language.

>write corporate software
>have to add 100 numbers together at worst or sort a database
>get to drive around in a sportscar, everyone treats you like a genius

>write videogames
>have to write code meant for engineering software, but it has to be extremely optimised
>do unpaid overtime, everyone treats you like a manchild loser

Why would anyone choose the latter is beyond me

Learn Lisp.

writing corporate software makes me want to kill myself
video games aren't any better tho

Pack cement bags for a week

Labor jobs can be pretty comfy if it's unionized and on a large construction site or something. I was making almost $100K signalling cranes, spent half the time doing fuck all. The only bad part is that to make that much you need to work a lot of hours for that sweet double pay.

I don't know why I stopped doing it, guess I was just tired of waking up at 5:30 everyday and working weekends.

Thanks for reading my blog

When you do an MD5 hash and append for the length to be 448 if mod 512, which length do you use when you write into the last chunk?

I forget, this is my C md5 implementation I wrote a few years ago. Too lazy to read it but it works.

pastebin.com/uNgd8RJ1

Source code: paste.debian.net/hidden/60c02eec/
+---------------------------------+
| What the hell is this fag shit? |
+-------------------------------\ |
\|
+--------------------------+
| The OP is supposed be be |
| cute anime _GIRLS_. |
| /------------------------+
|/
+---------------------+
| Fucking degenerate, |
+-------------------\ |
\|
____________ ---____ ______
/ /\ \ \/ \ /\ \
/ |\||/|/||\/\| // || v || \/\
c| \ || || | /_| || ||\/\ \
|\ \ U | || -- U --< -
/ \/|--------/ /^/\----------v^v-/
\/\/ \/

>be be

Yuno wouldn't swear like a whore

sizeof miya
R..rude!

fuck swift and xcode in the ass
fuck swift and xcode in the ass!
fuck swift and xcode in the ass!!
fuck swift and xcode in the ass!!!
fuck swift and xcode in the ass!!!!
fuck swift and xcode in the ass!!!!!
fuck swift and xcode in the ass!!!!!!
fuck swift and xcode in the ass!!!!!!!

Attached: Screen Shot 2018-12-15 at 5.48.21 PM.png (2160x1342, 560K)

Now add a command line argument to make them wider.

How would you insert an item to a certain spot in the list (in Scheme) ?

If bits could hold more than 2 values, how many values could a given data type hold?
Say a uint8 can hold 2^8. a uint16, 2^16
Would an N-sized ternary bit (trit?) data type hold 3^N values?
Would an N-sized X-"bit" type hold X^N values?

In my python3 code, I'm creating a queue.Queue object, but when i try to access after starting the asynchronous tasks, it is now a collections.deque object. I can't figure out where/why it's getting converted. Does anyone have any idea?

Use 'split-at' from SRFI-1. So something like
(let-values (((head tail) (split-at lst i)))
(append head (cons item tail))))

A uint8 is defined as an 8-bit integer. Calling an 8-character trinary nunber a uint8 is silly. Because, really, you could think of a 64-bit processor a base 2^64 system since it has no concept of units of data smaller than 64 bits. But they still exist at the abstraction level.

Queue.Queue and collections.deque serve different purposes. Queue.Queue is intended for allowing different threads to communicate using queued messages/data, whereas collections.deque is simply intended as a data structure. That's why Queue.Queue has methods like put_nowait(), get_nowait(), and join(), whereas collections.deque doesn't. Queue.Queue isn't intended to be used as a collection, which is why it lacks the likes of the in operator.

It boils down to this: if you have multiple threads and you want them to be able to communicate without the need for locks, you're looking for Queue.Queue; if you just want a queue or a double-ended queue as a data structure, use collections.deque

yes

OpenGL backwards compatibility question.
I have heard that I can use glTexImage3D to simulate texture arrays, but I have not found any examples out there on the internet.
PS: My computer doesn't have texture arrays, and I also cannot use sampler2DArray or texture() or texture2DArray() in my shaders.
(telling me to upgrade is not an option).

Sorry I can’t help you but how old is your computer?

a decade :^)

...

>using gaypple products
You asked for it.

thank you user

hackintosh

That makes you even gayer.

for you

Where do I start with Java. Recommended books or learning sites? I'll be going to college next fall and the class teaches Java so I'd like a head start.

>being gayer for me
Fuck off, faggot.

>Where do I start with Java
Shit in the streets.

Yes, each 2D image in the array becomes a 2D slice of the 3D image. Then you have to be careful with sampling to only sample individual slices and not between slices (you don't want filtering to occur on that axis).

I'm no pajeet.

Forgot to mention I've played with python times in the past and got the basic syntax and some simple concepts but it's been awhile.

nice, I actually came up with this
(define (insert! x n lst)
(append! (take lst n) (list x) (drop lst n)))

>I'm no pajeet.
>want to lean java
Could've fooled me.

>The OP is supposed be be |
> | cute anime _GIRLS_.
see:

(define (insert e i es)
(if (or (

It's what my school teaches. Plus it's what jobs ask for.

Too bad this is not linear iterative

wht this mean

Do you know if split-at is literally just (values (take lst i) (drop lst i))
or if it traverses the list only once

how do you indent like that? what are the rules? My emacs doesn't ident elisp like that automatically

>using emacs

Use paredit.

linear iterative means a recursive function which does not grow the stack, .i.e. a tail-recursive function

yeah but where is the documentation lol

I'm studying some TypeScript and holy fuck, why do people still use Javascript?

Probably because they haven't heard of alternatives.

Not sure, I think that almost every [1] reasonable Javascript developer have heard at least once about TS.

[1] citation needed

Actually, here's some data to back it up 2018.stateofjs.com/javascript-flavors/overview/

>tfw want to recommend Elm
>but 0.19 is a clusterfuck of an update and the whole ecosystem is pretty fucked right now

wikemacs.org/wiki/Paredit-mode

It's quite sad what happened to Elm.
I think for a language to succeed, it needs an actual company to back it, burning tons of money. Like how was done with Rust, Go, Kotlin and Swift.