/dpt/ daily programming thread

/dpt/ daily programming thread

Fuck weaboos
Previous - What are you working on, Sup Forums?

Other urls found in this thread:

darkdust.net/files/GDB Cheat Sheet.pdf
twitter.com/SFWRedditGifs

DELETE THIS!

>Posted before the bump limit
Report this thread.
Do not post in this thread.

Come on, fuckface, it was only at 297. That's not even close.

>Do not post in this thread.
user...

> (OP)
>>Posted before the bump limit
>Report this thread.
>Do not post in this thread.
>Come on, fuckface, it was only at 297. That's not even close.
Kek

bamp

Why is java disliked by so many people?

animuuuuuuuuuuuuuuuuu

...

What OS are you programming on Sup Forums?

I'm using Fedora right now on an older laptop.

>using Fedora
with an anime wallpaper?

Nope.

Lubuntu.

It works pretty well since I do most my work in the terminal anyways.

Ubuntu mate, it runs great on older hardware.

so gee, ready to get your mouth slapped with a big dick again?

Windows 10.

Only have the one pc and I like video games.

Why not dual boot?

Who /java/ here?
Java is the best programming language.
Also, F# is a meme and nobody uses it.

animuuuuuuuuuuuuuuuuu

I'm not mentally ill.

Because I'm only learning java for uni and eclipse works well in windows.

Currently have no reason to dualboot.

First year java student here.

>2 posts hidden
is the j*va pajeet back?

Kek

Ubuntu, actually, on my System76 Kudu laptop. For all the hate it can get, it's a reasonably comfy distro.

>First year java student here.
do you currently like java

Why does Ubuntu even get so much hate?
I love Ubuntu mate, it's a great distro.

what DE are y'all using with ubuntu?

MATE. It's a great, and lightweight, DE.

i'm java but i am jumping ship to c# because there are very little java jobs going round here compared to c#

wat do u pajeets think of this

Can be bloated, there's some spyware you need to disable (I think), Unity is... different, and Sup Forums likes things that are hard.

Standard Unity right now. Haven't gotten around to ricing or anything yet.

I used Awesome Tiling window manager (with useless gaps of course) with no DE back when I was on linux

>with useless gaps of course
of course, you're mentally ill

what debuggers do you guys use?
im trying out linux devving for the first time, but i absolutely refuse to use the gdb cli
i like gui's thank you very much

hello paje*t

>All of those false flags in the last thread

Visual Studio's debugging features are all I'll ever use.

Going to anything else is like swapping out your luxury sedan for a dirt bike, and I typically drive on well-paved roads, metaphorically speaking.

Because Canonical likes to reinvent the wheel just for the fuck of doing it diffferently than everyone else and because Ubuntu is the de facto Linux gateway distro so it's usually riddled with newbies that ask a lot of pointless questions because they can't RTFM but sooner or later people using Ubuntu realize that it doesn't really feel any niche and migrate over to better alternative and then act superior to people that still use Ubuntu and so on and so forth (by better alternatives I mean stuff like rolling release distros for desktop and CentOS/Debian/RHEL/SUSE for servers).

gdb -tui

Holy shit.

>RTFM
spotted the virgin

Not this guy but I had no idea this existed thank you so much

you're welcome
this might also interest you: darkdust.net/files/GDB Cheat Sheet.pdf

gdb or good old printf debugging.

...

>set up my first server
>hundreds of failed login attempts in a day

fucking chinese people

Idgi

>java student
is your program seriosuly called "java"?

static boolean isOdd(int n){
boolean [] truthTable = new boolean [n+1];
boolean previousEven = false;
for (boolean i: truthTable){
previousEven = (previousEven) ? false : true;
}
return !previousEven;
}

you should have done that recursive

>he fell for the recursion meme

u r a bad person

>he still can't into it

Does anyone know if VC++ merges identical string literals?

Why do you care? If it's a concern to you, place all your strings as (static) variables at the top your module.

enjoy your bloated stacks

const std::set x = { "A", "B", "C" };

I need to tie some key press combinations on Windows to an ios app. Like a remote.

How would Sup Forums start building such a thing?

gdb has all the features that VS has

Edit and continue?

from time import sleep
from copy import copy
from math import sin, cos
W = 32
H = 30
grid = [0] * (W * H)
ts = 0
def pixel (x, y, p):
if 0

I've never heard about that, but reading about it now, yes, you can do that.

Ooops change the sleep(1) to sleep(0.1)

Noice, but I think 1s delay is too much 0.1-0.2 looks way better.

Does having an array of pointers cause a lot of cache misses?

It depends, but it probably will.

Yea I accidently fucked up
and I would like to not take credit for 90% of this code wich is made by other user

Depends on how the memory the pointers are pointing to was allocated.

Would it though?
Would the CPU do a check on every pointer to check it's in a cache line even though there are 2^32 or 2^64 possibilities?

Openbox.

Newfag here. What's the big deal with making new threads before bump limit? Anyone can post in either one right?

Why not just screenshot?

dont ask
its just a bunch of faggots arguing about completely inane shit

Just got a new computer and I need programming software.
Gonna reinstall the basic Eclipse and shit, what else is there? Don't care about the language, just give me all coding programs.

It splits the thread and encourages posting new threads earlier, also encourages posting multiple threads and posting threads because you don't like the image

Same. Only reason I even have visual studio is the debugger.

You get faggots (like OP for example), who will post their stupid forced memes or other garbage, and then you get competition from a whole bunch of other faggots, leading to threads being made earlier and earlier.
Having two threads up at the same time is not a good thing, wastes board space, and leads to confusion about what thread is supposed to be posted in.
Also, pre-posted threads, and threads with anything (besides the standard /dpt/ template) are rife with shitposting.

I highly doubt this.

Performance profiling, milliseconds between steps, and you can drag back to a specific point in your code and re-run a statement.

Watch lists, locals, autos (with neat things like telling you the result of a function, even if it's not assigned to a variable), stepping into enumerables, etc.

>neat things like telling you the result of a function, even if it's not assigned to a variable
exactly. In gdb I can't even check the size of a c++ vector without assigning it to something.

Here's an example of drag-and-drop debugging.

Basically, you can just drag the current execution indicator to a line and go back and run it again and try different values for testing, no recompilation needed.

The 'autos' tab is an automatic window that tracks all variables in the current scope.

>autos
Locals*

Autos tracks the last couple of statements, while locals is the entire current scope.

>Performance profiling, milliseconds between steps
That's not a task of a debugger.
>you can drag back to a specific point in your code and re-run a statement.
>Watch lists, locals, autos (with neat things like telling you the result of a function, even if it's not assigned to a variable), stepping into enumerables, etc.
You can do all that.

>step back n statements
>change values on stack/heap/register
>run

Drag-and-drop™

>what are non-bijective functions

>You can do all that.
GDB does not have all of these features, and some of the implementations are not even close to being as user-friendly.

Some additional things include conditional breakpoints, and breakpoints that do things, such as write to console. You can also have a breakpoint count how many times it had its dick tickled without polluting your code with a counter.

>they are in gdb because its not user friendly enough for me

okay lad

>not even close to being as user-friendly
Subjective.
>conditional breakpoints
>breakpoint count how many times it had its dick tickled without polluting your code with a counter.
gdb has that.
>breakpoints that do things, such as write to console
That's not really applicable to CLI.

I think I'm confused. Do you really think gdb doesn't have conditional breakpoints?

>I'm illiterate and misunderstand basic sentences.

Look, GDB is great, and if you don't have access to Visual Studio with your platform, then GDB is a great choice. There's just no reason to use it if you have access to superior debuggers.

I was just listing nice things from the top of my head. I'm aware that GDB has many of these features, but not all of them.

Only bad programmers need debuggers

Hello there, NEET.

Only bad programmers debug

I have a job, your point is moot.

Only bad programmers write code.

Only bad writers program

Only bad programs write.

Whatever floats your shillboat.

I also figured the best way to write a game is to delete kernel code until I get the result I want.

rewrote

from time import sleep
from math import sin, cos

W,H = 32,30
grid,ts = [0] * (W * H),0
def pixel (x, y, p):
if 0

looks really nice thats amazing.

I download the source code for an ios app and when I open it it has a bunch of errors. I'm guessing this is because it was made on an older version of xcode or swift or whatever. Why are these errors a thing? Surely each update fucks up a load of old apps.

What is this?

I have a retarded question but I didn't find any answer online.

How can I insert an int value in a int field that will add to number already there ? (in a SQL table )
Let's say I have a table human with his name and his age.
I want to add 23 to robert. His age in the table is 50 so I want it to be 73.

SET `age` = `age` + 23