/dpt/ - Daily Pascal Thread

program dpt;
begin

What RAD projects are you working on today, Sup Forums?

Previous thread: end;

Other urls found in this thread:

github.com/niklasvh/html2canvas
github.com/p-org/P
doc.rust-lang.org/book/second-edition/ch15-00-smart-pointers.html
twitter.com/SFWRedditImages

Is it possible to code an "app" that will screenshot a selected Sup Forums post and, if desired, save it to my computer? I'd a web designer so I guess my forte is the more creative side of technology and I'm not sure what's possible and what's not. I guess my ideas sometimes exceed reality in a sense? Haha

>app
>I'd a web designer
"no"

haskell!

stop fucking with the classic /dpt/ thread format you fag

> Pascal
lel brainlet

I prefer C

Why are people so afraid of statically typed languages?

good post!

C++!

stop posting

Scheme?

Rust!

bad post!, dumb nigger.

get out

Lua!

this

bit childish desu senpai

...C?

>end
>endixing from 1
dumb lua poster.

Not a webdev by far, but you could select it by ID, download JSON, parse it, find the text of the post and generate the image yourself.

Islam!

maybe in the 1980s

That's why I use it with LÖVE to make vidya.

>not ending your blocks with 'end'
>the first element is element number 0
dumb C brainlet

>arguing about such petty things.

The single most sad thing about Lua is that everything is global by default.

Otherwise it's a pretty neat scripting language, I like it a lot. 15k lines of clean C, 10k if you exclude the standard library, interpreter and bytecode compiler. Neat and lightweight, perfect of embedding.

t. pleb

Which programming language would Aggy use if she were a cute anime programming girl?

Anybody know an easier solution?

This image made me laugh

none because programming is sexist and she looks like a giant SJW because of the friends she hangs out with

>not using c++ and sfml

>not using c++ and sdl

>not using C11, GLFW3, glad to load OpenGL ES 2.0 and libsoundio.

>take screenshot of post
>pop up appears asking if you want to save it
>????
>profit

100 million pixels user
just for you

github.com/niklasvh/html2canvas
might get you started.

You're just mad because your favourite language's name doesn't start with a "P" so you can hijack /dpt/ shoehorning its name onto it.

>not using Allegro

>not using assembly and programming your gpu directly

Any Nim fags here? How do I dereference an object?
let input = stdin.readLine

let keys = input.splitWhitespace.deduplicate

var counts = new seq[(string, int)]
for key in keys:
counts.concat((key, input.count(key))) # type mismatch, got ref seq[(string,int)]

This is a traditional foreach loop:

for (String name : names) {
System.out.printf("Hello, %s!\n", name);
}

This is its object-oriented alternative:

new And(
names,
n -> {
System.out.printf("Hello, %s!\n", n);
}
).value();

Or D. Or T.
3k of JS. Maybe I should learn JS, it doesn't seem so bad, even has an ISO standard.
Allegro is bloated.

>foreach loop:
No, it's just a shitty placebo
Here is a real one:

foreach (index, item; range) {}

>D Programming Thread
>Daily Programming in TCL

>everything is global by default.
what the fuck why would they do this

>Delphi and Pascal Thread.

I'm trying to get a genetic algorithm to design analog circuits (amplifiers)
My first version would have the output converge to the sinusoidal input and I don't know why (I was trying to achieve 'x' gain)
I tested my GA with other functions so I don't think it's the cost function
On version 2 right now, but close to giving up :/
>nice blog post

Mature women are all the hype these days.

only kiddie languages start with a "P"

Probably to make it easier for beginners.
Even semicolons are optional.
You can write bug-ridden garbage and it'll still run, you'll have no idea that every variable is global until your logic falls apart and you don't know why.

>fortran
anyone actually use this

this kills the programmer

It was initially designed for people without any prior coding experience. So it was simpler to explain and worked fine for small scripts (and you should never make anything big in dynamic language anyway).

This can be solved by typing local before each variable and using a static analyzer to tell you where you forgot to do that. Makes seeing where variables are declared easier, as a side effect.

>anyone actually use this
not kids like you, that's for sure

>Prolog is for kiddies
>Pure Data is for kiddies
KYS

2 tru

>php
>python
>perl

I actually moved to LÖVE from C++ and SFML.

i recognise that vid

...

P-P-P-POWER SHELL

Which poster were you? What was your suggestion? Mine was the C11 one.

>not using P

github.com/p-org/P

ocaml!!

OpenGL question. I want to try to render all sprites from MULTIPLE textures with a single draw call (assuming I don't have more textures than there are texture units available). I thought about storing the texture index in the instance array and the doing a binary search in the fragment shader to invoke the correct sampler. Is this the way to go or will the GLSL police knock at my door?

cringe kys

I've been much more productive with LÖVE, even if my games now only run at 3000 FPS instead of 10000 FPS.

post a screenshot of one of your games

I found that image on Know Your Meme earlier today and saved it. It's like the time I came across a video of a pig eating a cookie on Youtube and, in the next thread I saw on Sup Forums, someone had posted a screenshot of the video. This simulation in which I live is not very convincing tbqh.

>Perl
>kiddie language

how do I use a smart pointer?

>not using atomic smart pointers

what are you even doing

Reply to this post with three programming languages that are worthwhile and shouldn't be purged from this dimension.

ez
doc.rust-lang.org/book/second-edition/ch15-00-smart-pointers.html

You need to call the smart pointer constructor with the pointer as an argument.

{}

rust, go, python

>all sprites from MULTIPLE textures with a single draw call (assuming I don't have more textures than there are texture units available). I thought about storing the texture index in the instance array and the doing a binary search in the fragment shader to invoke the correct sampler. Is this the way to go or will the GLSL police knock at my door?

Generally, if statements destroy parallelism. Switch is a jump table though, so it could work.

No, languages that SHOULDN'T be purged from this dimension.

Also when free the surface you need to call the get method rather than feed the smart pointer. The smart pointer is a wrapper around a pointer, not the pointer itself

...

exactly

I'm retarded, pls help.

C11, Lua5.3, Python3.7

i dont want to kiss you

C

Don't know why you'd need anything else.

>Lua5.3, Python3.7

K I must be dumb because I didn't think about switching, thanks

stop using rust k thx
rust needs less dumbass programmers shitting up the ecosystem

To make graphical applications.
To make applications that don't require performance quickly.

pleb detected

He's using C++...

on that topic which languages offer GUI libraries that arent shit?

Do you think it would be more efficient to do one draw call per texture?

t. certified fizzbuzz programmer

>What is SDL

>t. brainlet

Cant tell if you're meming or just retarded

Why is the top of his head all long and floppy?

>t. certified pythonista

t. joblet