Previous thread: What are you working on, Sup Forums?
/dpt/ - Daily Programming Thread
Other urls found in this thread:
C#
>C# C++
>t. hasklel 'developer'
>t. drakeposter
>the haskell "language"
>drake
Never forget: You can still give up.
dumb drakeposter
>python
>java
(((Lisp)))
> not qt anime girl in op pic
What normies forgot here? Shitoverflow is over there
Currently attempting to use C# to call a function inside another process. My first thought was to use CreateRemoteThread with the function address as the lpStartAddress, but the function expects multiple arguments, so I can't just pass one parameter via lpParameter. Trying to avoid having to write my own asm stub that gets called.
Attempting to use delegates right now, but without knowing the method signature, and return type, I'm finding it quite difficult to put together a delegate that actually works.
Using EasyHook for the function hooking part, but it doesn't ever seem to like my function pointer. I have found the function in OllyDbg, and when I put a breakpoint on it and do what normally calls the function, the breakpoint triggers, so I'm almost positive the address I have is the address of the function. When I try using that address in Marshal.GetDelegateForFunctionPointer, it tells me it's an invalid function pointer.
Any suggestions?
>liking anime
>C#
Hey guys pretty fucken bored was thinking of writing a Gameboy emulator, was thinking maybe I could render it through SSH using ASCII art but that seems kinda unlikely any ideas?
>not liking anime
>Not using C# in 2016
>top kek
>anime fans always get triggered when you say you don't like anime
cute
>18xx and onward
>using C#
top kek
you don't like anime
I'm trying to write a rootkit in python.
Any tips?
What do you use then?
((((((((((((((pascal))))))))))))))?
>not liking anime
First and last for Ada
it worked:
>pascal
#import rude
#import kid
#import rootkit
that should do the trick
Visual Basic.NET is the superior language.
>tfw get memed on Sup Forums but still get paid more
I love Java
I'm thinking about creating my own computer programming language. My current working name for it is cumsharp. It will be a Forth dialect with dependent typing and a flexible tree-structured stack (t-stack). Runtime size will be 100MB.
make it 137.7MB instead LOL
ROFLMAO
Python is actually awesome
g danks
>Python is actually total shit
seems like you made a typo friend
>not using C# in CurrentYear
>No matter how many mistakes you make or how slow you progress, you're still way ahead of everyone who isn't trying.
How is this supposed to be motivational? I'm only marginally more successful than people who aren't even trying?
>using C# post 1918
>way ahead
>marginally
But yeah, i agree with you. I'm not way ahead of anyone that counts.
What makes C# any better than Java?
nothing
their both DOGSHIT of the highest order
It's name
The D language. What's it all about? Why should I learn it?
>liking anime post 1488
It's the D in CrossDresser
>implying C# is a better name than Java
>implying python is better than either
LINQ
What the fuck is LINQ
SQL for C# collections
Yes, C# really is this retarded.
Fuck you pajeet, LINQ is amazing.
I bet you think SQLServer is the best thing ever too, don't you?
PHP
LINC is the computer controlling the city in Beneath A Steel Sky
Wow, spoilers.
>non-sequitor
>meme words
>multiple little capybaras
Most words are meme words
Gorgeous!
....for a rat.
>liking capybaras
this entire thread was automated today.
gross.
also, has anyone noticed Terry Davis is like a time crawler. Dude is a god.
>not liking capys
>round a compass degree to the nearest 5°
Experienced project manager:
for (i=1; i= ((i*5)-2)) && (input = 360) ? 0 : output;
not really anything, it's worse by far, except maybe in a windows-oriented ENTERPRISE environment
the first one is so bad he should get fired
#import compass
#import degree
How the fuck does the second one work?
why is *5on a separate line?
Couldn't you just use the modulo of the input with 5 to get the remainder?
Shouldn't you be answering telephones, Pajeet?
Feel free to answer my question.
Play with the math and figure it out
integer division truncates the result
What part of it do you not understand?
Probably in case of compiler funny business with (x/5)*5. Looking at the assembly it's only an extra STR and LDR instruction so it can pass.
Get the remainder, check if it is greater than 2, and then conditionally add or subtract? Explain.
I forgot that the decimal is completely dropped, rather than rounded.
>Probably in case of compiler funny business with (x/5)*5
the compiler would have to produce the same result
if(input == 0){
output=0;
}else if(input == 1){
output=0;
}else if(input == 2){
output=0;
}else if(input == 3){
output=5;
}else if(input == 4){
output=5;
}else if(input == 5){
output=5;
}else if(input == 6){
output=5;
}else if(input == 7){
output=5;
}else if(input == 8){
output=10;
}else if(input == 9){
output=10;
}else if(input == 10){
output=10;
}else if(...
At least that provides the correct result for 1, 2, 358 and 359.
math or engineering oriented studies, which path did you go / are you gonna go?
that's a Sup Forums-level (i.e. completely worthless) idiom for rounding positive integers on a grid. Since, C99 it definitely doesn't work on negative numbers. Before it was implementation defined for negative numbers, which is worse.
It's based on equality floor(x/n + n/2) = round(x/n).
I'm not him, but he suggests something ugly like this
m = x % 5;
y = x - m + 2 * (m > 2) * m;
>Not using a select statement
Not very efficient there
What's a select statement? A switch case?
What makes you think those are more efficient?
Electronics engineer gave me a lot of options, including being a programmer. I didnt even anything the things Im doing now on college though.
I think a math course has more girls if you want to get laid easier
If you wanna get laid and still pursue STEM you should do something along the lines of biology.
while(1) fork();
Why not just use guys? They have holes too.
>biology
>STEM
pick one
Words are memes by deffinition
>C/C++
>MATLAB
>Python
>Bash
>Lua
Well they are languages at least. How fucked am I in choice of languages?
It's a hard science.
C and Lua are both decent.
Pretty sure a compiler would optimise it.
> computer nerd thinks he could understand biology
You wouldn't last 10 minutes.
> HTML5
> CSS
> SQL
> RegExp
> A little bit of programming in Turing machines
They are pretty much the best for their intended purpose.
>matlab has no purpose
>understand
>biology
More like memorize m8
No, more like this:
int m = x % 5;
int y = m < 3 ? x - m : x + 5 - m