[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

/dpt/ - Daily Programming Thread

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 345
Thread images: 25

What are you working on, /g/?

Old thread: >>59734442
>>
>>59747138
Lisp is the most powerful programming language.
>>
>>59747156
What about the most powerful race?
>>
delet
>>
File: vbe3.png (121KB, 1073x1154px) Image search: [Google]
vbe3.png
121KB, 1073x1154px
daily reminder
>low-level C++
>high-level comfy
but graphics programming still sucks.
>>
>>59747141
>>59747149
the dpt roll said us either 1.
Do I just go with the one that's easier to work with?
Or do I make things harder on myself because I'm learning?
>>
How would you write 36 in base 37 system?
>>
>>59747177
>low-level C++
C?
>>
>>59747182
Depends, what are you using for 10-35
>>
>>59747182
Invent new symbols.
>>
>>59747178
If the input is has 3 or more digit, assume it is date.
If the input is lesser than 2 digits, assume it is age.

I am sure you can come up with actual ways to check the validity of both.
>>
>>59747182
With your last symbol. 37 would be 10.
>>
File: 1472493166371.png (179KB, 463x492px) Image search: [Google]
1472493166371.png
179KB, 463x492px
>>59747177
So are you basically using C++ like C with classes?
>>
>>59747194
You da real mvp ty.
>>
>>59747177
this is all one function isn't it?
why does it even need to be in assembler?

this is just gross all around
>>
>>59747189
>>59747197
do you see me using void pointers or macros anywhere?
no? then it's c++.
>>
>>59747194
What if I'm 100 years old?
>>
>>59747218
can't call 16-bit far pointers without asm, unfortunately.
>>
Not only will my language have dependent types and affine types. It will also support writing code with different sets of primitives in order for the language to be able to compile to e.g. SPIR-V for use with a Vulkan application. The Vulkan library can then provide a library that lets you write high-level shaders in the language itself which have compatible types with ordinary code.
>>
>>59747226
Then make it 4 digits or more for date and a prompt that says are you fucking seriously 100 years old when you use 3 digits. Unless you can come up with a fucked up method to input a 3 digit date.
>>
>>59747237
no bitmasks?
no function pointers?
>>
>>59747258
?
how would I express a far pointer as bitmask or (near) function pointer?
>>
>>59747182
(10)36 - 1
>36 is a subscript
>>
My language will have a background thread that goes through pointers and sets a few to null without warning.
>>
>>59747288
if you're getting the lower 8 bits you could just do

void (*ptr)() = far_ptr & 0xFF; 
ptr();
>>
>>59747321
the whole point of far pointers is to call code in a different segment. you can't do that with near pointers.

and by "16-bit far pointer" I mean one that has a 16-bit segment and offset. so it's 32-bit total. you also need to call it from an address that resides below 0xFFFF in the current segment, and I'm doing that by copying the asm block to a new segment and calling that through a 32-bit far pointer (which is really 48-bit).
>>
File: programmer_employability.png (27KB, 520x544px) Image search: [Google]
programmer_employability.png
27KB, 520x544px
How are you working towards employability?
>>
>>59747413
>working as a programmer
I do this shit as a hobby, bud.
>>
>>59747413
If bubble sort is 1/4 then that's pretty low barrier of entry. Honestly I don't even get this meme of employers making you write inefficient algorithms or code just to make sure you can write syntax properly.
>>
>>59747420
I'm taking you don't work trades, seeing as you have the energy to devote to programming after hours.
>>
>>59747430
It's just a retard filter.
Most people who claim they can code have never written code.
This is only because there's no vetting process for programmers, no organizational body that hands out certification like every other engineering field and keeps the retards from applying.
>>
I'm learning how to add a tooltip to my text when you hover over it with HTML.

Suck it nerds
>>
>>59747446
title attribute my friend.
>>
I keep getting index out of range. for age[count]
I'm not sure what I'm doing wrong here.
I thought lists started at index 0? Please explain why I'm stupid.

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Text.RegularExpressions;


namespace ConsoleApp6
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Please writ age or DOB");
String input = Console.ReadLine();
String[] temp = Regex.Split(input, @"D+");
var Age = new List<int>();
foreach (String inte in temp)
{
int count = 1;
if (!String.IsNullOrEmpty(inte))
{
int num = int.Parse(inte);
Age[count] = num;
count++;
}

}
foreach (int c in Age)
{
Console.WriteLine(Age);
Console.ReadLine();
}

}

}
}

>>
File: 1470950158496.jpg (111KB, 1252x1252px) Image search: [Google]
1470950158496.jpg
111KB, 1252x1252px
>at interview
>guy asks me to tell him what some hexadecimal number means
>It's not some simple short one, it's like a good 6 characters all over the place

That was the worst interview ever, he ridiculed me for not being able to solve it on the fly. This was for like a web-ish job too
>>
>>59747462
Age.Add(whatever);
>>
>>59747467
>he can't read hexadecimal without conversion
Why are you even here?
>>
>>59747467
every letter is 4 bits
you could change them to numbers and write out little 4 number clusters of binary and count it up manually

or would I fail the interview for this too?
I wouldn't know, I've never been called in for an interview despite sending over 200 applications.
>>
>>59747467
Had interview today too.
Guy wanted me to explain some of the programming I've done in the past.

I could tell him all about what the program did and the logic behind getting it to work.

But for some reason i couldn't explain the actual code put into it. I had to dance all around it and pray he knew that I knew what I was talking about.
>>
>>59747467
>webdev
was it some color code crap?
>>
>>59747443
>>59747430
>>59747467
I've honestly only had 3 places make me code anything as part or before the interview. Granted I've only be invited in about 8 times at most... Anytime you get with someone in hardware or non-technical I feel like they don't give a shit if you can write from fizzbuzz and just want to make sure you understand the concepts they need.
>>
>>59747470
Thanks
>>
>>59746490


update from this..

(yes, im still retarded)

https://pastebin.com/hdB4MsJ4

I got it to compile and everything, but no matter what I input, its always found

Fuck.
>>
File: out.webm (706KB, 1280x720px) Image search: [Google]
out.webm
706KB, 1280x720px
>>59747138
I'm working on a game that will be a bit like a fusion of NetHack and Dorf. I'm writing it in C++ with pthread and pdcurses. All I have right now is a basic main menu and the beginning of world creation.
>>
File: test (2).png (716KB, 811x599px) Image search: [Google]
test (2).png
716KB, 811x599px
>final stage of interview for a faculty position at IQC
>the committee asks me to find a decision procedure for the spectral gap problem of a general locally finite-dimensional nearest-neighbor lattice Hamiltonian
>mfw
>>
>>59747546
your Find should work but this
if(&x !=NULL)
{
printf("found\n");
}

is broken. x is never null because it is input by the user. you want.
if(Find(root,x) != NULL)
{
printf("found\n");
}
>>
>>59747413
I'm already employed
>>
>>59747611
What's your resume like and how was your interview?
>>
>>59747589
you're a beautiful person.

although, im not sure why it asks for user input twice
>>
>>59747617
At mcdonalds
>>
>>59747632
Lmao found the /soc/ fucciboi
>>
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Text.RegularExpressions;


namespace ConsoleApp6
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Please writ age or DOB(m/d/y)");
String input = Console.ReadLine();
String[] temp = Regex.Split(input, @"[^0-9]");
var Age = new List<int>();
foreach (String c in temp)
{
if (!String.IsNullOrEmpty(c))
{
int num = int.Parse(c);
Age.Add(num);
}

}
int[] Number = Age.ToArray();
if (Number.Length == 1)
{
Console.WriteLine("You are {0} seconds old.", Number[0] * 31556952);
}else if (Number.Length == 3)
{
int x = Number[2];
if (x > 17)
{
x = x + 1900;
}
Console.WriteLine("You are {0} seconds old.", (Number[0] * 2629746) + (Number[1] * 86400) + ((2017 - x) * 31556952));
}
else{
Console.WriteLine("Next time Just put your DOB or age.");
}
Console.ReadLine();
}

}
}



So how did I do guys? How can I make this more efficient? Yes I see the logical error. I will fix it tomorrow.
>>
R8 my prime sum :^)
function isPrime(n:int):Boolean
{
if(n <= 1) return false;
var sqN:int = Math.sqrt(n); // Only need to check upto the root of n
for(var i:int = 2; i <= sqN; i++) {
if(n%i==0) return false;
} return true;
}
var primes:Vector.<int> = new Vector.<int>;
for(var p:int = 1; p <= 2000000; p++) {
if(isPrime(p)) primes.push(p);
}
var primeSum:Number = 0;
for(var s:int = 0; s < primes.length; s++) {
primeSum += primes[s];
}
// trace(primes);
trace("Sum of the primes below 2 000 000:");
trace(primeSum);
>>
>>59748014
if(n <= 1) return false;
if(n%i==0) return false;
if(isPrime(p)) primes.push(p);


Do people really code like this? This is so fucking disgusting
>>
>>59748033
>Do people really code like this?
And you propose i waste space with { } instead?
>>
>>59748045
Oh? What do you do with all the space that you save?
>>
>>59748059
>Oh? What do you do with all the space that you save?
Admire the elegance of proper as3 code.

What do you do with all those brackets of yours?

Though i must say that im curious to why you prefer
if(foo) {
bar();
}

to
if(foo) bar();


Please, do share your views.
>>
>>59748078
consistence and readability
>>
>>59748086
Hm, i see your point, but i find it cluttering.
IMO its simply seems like a waste to spend 3 lines on 1 check

Also, i find
if(foo) { bar(); }

disgusting
>>
>>59748099
Maybe it is because I am used to working on programs with large amounts of code. Saving 3 lines on 1 check gains you nothing except maybe a "minimalist" look but those 3 lines will save you a lot of headache if your code bloats to over a 1000 lines and you have to troubleshoot stuff. Reading code in a consistent manner is always a good habit to have because at the end of the day you are the one that is going to be spending the hours re-reading it again.
>>
>>59748133
I'm used to working with similar programs, actually. And i can kinda see where you're coming from
Usually tho, i do checks in larger bulks, and rarely find myself having to do small tests like that

Nonetheless i still write my if's the same way, and I've yet to encounter any issues... but that might just be a matter of time. I do isolate check a lot as well though.

I must commend you for keeping this civil and not shouting
>"OMG ANON YOU DONT DO STUFF THE SAME WAY AS ME, GEEZE"
>>
>>59748180
I used to write my code in a similar manner as you. The shorter the sentence and lesser the lines the better even if at the end of the day it is functionally the same thing.

Then I realized the trade off I got didn't mean anything. Writing code in a consistent manner with consideration for the future me would might need to troubleshoot problems is the better option.

Also I am glad that we can have a civil discussion about this topic.
>>
Can someone recommend an up to date resource for graphics programming with modern C++. Bonus points if it has good exercises.
>>
>>59748892
Any will do. No one really does graphics programming in C++ nowadays. Every decent company will have their own inhouse engine or licensed engine to use.
>>
Do a lot of people in the industry use drugs like adderall?
>>
>>59748954
The engines are still written in sepples even though the games might be programmed in lua or some other shitty "meme game engine scripting language of the week"
>>
>>59748972
What is your end goal? Writing your own engine in C++?
>>
>>59748892
working on this right now and I have no idea what the fuck I'm doing.
>>
>>59749026
I mean, I got to the part where I can plot pixels on the screen. plotting them in the right position, that's the difficult part.
>>
>>59748892
I think learnOpenGL has OGL4 resources. That would be best to start. Then look at vulkan.
>>
>>59748999
No end goal, just interested.

>>59749108
Just had a quick look at it and it seems very good, thanks a lot.
>>
>>59747488
well if you were asked to convert hex to decimal you should probably just do it directly which is just adding up the 1-15 values per digit to the corresponding power of 16 it refers to (1st digit being the ones, which is 16^0, 2nd being the sixteens which is 16^1, the 256s which is 16^2 etc)

another method to do that from left to right of a number which is less computational effort is to just start at 0 as your answer, multiply your answer by 16 and add the digit to answer
if you were given a string it'd look like something like this

String digits = "0123456789ABCDEF";
int val = 0;
String input = "1AD7F"
for (int i = 0; i < input.length(); i++) {
char c = input.charAt(i);
int d = digits.indexOf(c);
val = 16 * val + d;
}
>>
Got about 5 weeks to work on a school project.

Gonna make a group chat system using Raknet and C++. I've got a server-client setup working already and clients can send messages to each other like expected.

What other features should I add in the time I have? I'm thinking:

>Add timestamp data to chat messages, and a 'read' status that other users can see.
>Add support for emoticons/emojis.
>File transfer (I can do .txt files already but I had issues with all other files).
>Be part of multiple conversations at once. Keep updating inactive conversations as a background process.
>Kick clients/add clients

Anyone wanna toss in any other ideas?
>>
>>59747138
Is there any way to store large chunks of data locally with Javascript without having a mysql server?
>>
File: absolutelyamazing.png (77KB, 648x546px) Image search: [Google]
absolutelyamazing.png
77KB, 648x546px
oh wow I can draw spirals now.
>>
>>59749562

Neat.
>>
>>59749507
>Add timestamp data to chat messages
Make sure it's adjusted with local time. Also unicode support.
>>
>>59749581
took only 9000 lines of code, but hey.
$ cloc . --exclude-dir=obj,bin
73 text files.
73 unique files.
16 files ignored.

https://github.com/AlDanial/cloc v 1.66 T=0.11 s (650.9 files/s, 105877.1 lines/s)
-------------------------------------------------------------------------------
Language files blank comment code
-------------------------------------------------------------------------------
C/C++ Header 48 941 696 5343
C++ 21 407 298 3656
make 1 12 0 34
-------------------------------------------------------------------------------
SUM: 70 1360 994 9033
-------------------------------------------------------------------------------
>>
>>59749609

It's all worth it when you can draw spirals.
>>
>>59747549
nice
>>
>>59747853
What was the purpose of making "Age" into an array? You can get the Count property on lists, and you can access them with indexes, too.

Local variables should always be camelCase; because other identifiers are in PascalCase, this makes your code difficult to read in some places.

Also, if I tell you that I am 26, that does not mean I am
26 * numberOfSecondsInAYear
old; that shouldn't even be an option, in my opinion.

Lastly, it would be better to convert the DOB into a
DateTime
, so then you can use
TimeSpan.Seconds
to get the difference between the DOB and
DateTime.Now
>>
>>59749609
Nice cloc Danial.
>>
>>59747853
Not trying to "one-up" you, but consider the following:
WriteLine("Write your date of birth. (YYYY/MM/DD)");
WriteLine($"You are approximately {(int)DateTime.Now.Subtract(Convert.ToDateTime(ReadLine())).TotalSeconds} seconds old.");
>>
hello i am new to java how do i build neural network for learning machine for video game
>>
Is it a good idea to freelance?
If yes, what kind of freelancing website does /g/ recommend?
>>
finding reasons not to kill myself.
>>
>>59750416
>reason #1: I would be dead
>Oh, maybe I shouldn't kill myself.

>>>/r9k/
>>
>>59750430
not an argument
>>
what are your predictions for the future of programming? (i.e. what new shit will be big within the next 10-15 years)
i think docker and containers will all but replace regular hosting soon, they just have to fix the networking challenges
also i want AI to become more sophisticated and generalized, but its probably just wishful thinking
>>
I am working on a PlayStation game using Unity
>>
>>59750474
>>>/vg/agdg
You need to go back.
>>
File: 6cf.png (361KB, 858x725px) Image search: [Google]
6cf.png
361KB, 858x725px
>at work studying
>coworker asks what I'm studying
>I say make and makefiles
>he replies 'lol wtf why makefiles, why not study how to write web.configs instead'
how do I stop myself from commiting murder
>>
>>59747467
if it was a web job that 6 digit hex number would have represented a 24bit colour in which case you definitely should have been able to interpret it on the fly. good filtering interview man
>>
>>59750714
by killing your retarded coworker
>>
>>59750714
>guys do i fit in yet
>>
>>59750755
it's a real story, don't care if you don't believe it
>>
>>59750714
>Posting that facebook frog

>stop myself from commiting murder

start with yourself
>>
>>59750714
>>59750755
>>59750783
Who are you quoting?
>>
>>59750768
>studying makefiles and make at work

sure thing buddy
>>
>>59750792
Who said that?
>>
>>59750792
it's at work but not for work :^)
>>
>>59750788
read this sentence.
>>
>>59750807
Just did. So who were you quoting?
>>
>>59750816
read this sentence.
>>
>>59747138
"The most powerful programming language is Lisp. If you don't know Lisp (or its variant, Scheme), you don't know what it means for a programming language to be powerful and elegant. Once you learn Lisp, you will see what is lacking in most other languages." -Richard Stallman
>>
>>59750838
I don't know what you are implying with this.
>>
>>59750859
>Richard Stallman
stopped reading right there.
>>
>>59750873
too late
>>
>>59750860
>who were you quoting
I don't know what you are implying with this.
>>
>>59750905
You quoted something which hasn't been said before.
>>
who are you replying to?
>>
>>59750965
go read the rules what quoting is newfag
>>
>>59750807
>>59750816
>>59750838
>>59750860
>>59750905
>>59750965
>>59750972
>>59750990
Holy shit, fuck off.

Here's a (You) for the road.

>>>/b/
>>
for x in xrange(1, 200):

fizz = not x % 3
buzz = not x % 5

if fizz and buzz :
print ("FizzBuzz")
elif fizz:
print ("Fizz")
elif buzz:
print ("Buzz")
else:
print (x)
>>
Are either of these considered more correct than the other in C++?
I've seen people do both in similar situations.
void Vector2f::normalize()
{
x /= mag;
y /= mag;
}

Vector2f& Vector2f::normalize()
{
x /= mag;
y /= mag;
return *this;
}
>>
>>59751168
#.(loop for i from 1 to 100 do
(format t "~:[~:[~a~;Buzz~]~;Fizz~:[~;Buzz~]~]~%~@*" (zerop (mod i 3)) (zerop (mod i 5)) i))
>>
>>59751314
actually i think:
Vector2f Vector2f::normalize()
{
Vector2f copy = Vector2f(this);
copy.x /= mag;
copy.y /= mag;
return copy;
}

is the most popular
>>
>>59748180
I can confirm the consistency point. I can't remember whether i started off writing checks over 3 lines as the other anon mentioned or if it was because of standards and guidelines i had to follow at the time, but i find it a bit easier to debug and troubleshoot when all the code follows that kind of convention. Like the other anon mentioned, When some clown has written classes hundreds of lines long and something goes south, consistent, clear, human readable structure and formatting helps more than what i would've thought when i first started programming, and usually slightly more verbose but more clear structure helps me in that regard
>>
>>59751168
>>59751317
dofizz : Vec 100 Fizzbuzz
dofizz = fizzbuzz 1 100;
>>
I want to write a script so that I can easily log bad login attempts to a system and store it in some sort of meaningful way.
But that last part is my problem: I want to parse the output as a list of lines of semi-colon separated data. How do I do that? Obviously I need to
lastb -f /var/log/btmp
, but how do I parse the output as I wish?
>>
>>59751370
For a more comprehensive field-like class we'd expect a friend function normalized(const vec&) (and yes no modify).

But if I had a limited use for the class I'd have a modifying method because why the fuck not eh?
>>
>>59751702
Not sure why I said field, since a vector is not a field unless it's 1-dimensional. Still though I mean a more 'number-like' class. Like std::complex.
>>
>>59751702
problem with mutating version is you cant chain it with other code
i.e. you have to do
vec.normalize();
vec.mult(5);
vec.length();

instead of
vec.normalize().mult(5).length()

or
length(mult(normalize(vec), 5))
>>
>>59751772
That's more a problem with the version that doesn't return anything.

The mutating version is a bit more convoluted in that scenario nonetheless.
>>
Just found out about the Web Bluetooth API in Chrome, so I'm going to mess around with a BLE heart rate meter

Going to make an interval timer to measure the aerobic threshold or something
>>
>>59751877
sounds pretty cool, whats aerobic threshold? like the bpm sweetspot for max gains or something?
>>
Is there any idea in using structs with function pointers instead of classes?
>>
>>59751929
He probably has diabetes or some bs
>>
>>59751932
There's no reason to use classes, so I guess.
>>
>>59751932
if you're using C, which you shouldn't
>>
>>59749548
Sqlite on the desktop or localstorage in the browser.
>>
>>59751932
Sorry for being autistic but structs and classes can produce the same types in C++, what do you mean exactly?
>>
>data structures course
what am i in for?
>>
>>59751969
a course on data structures
>>
>>59751969
probably wont be about concurrent data structures
>>
>>59751981
>>59751986
>linked lists
what a meme
>>
>>59751942
How does that tie into aerobic thresholds?
>>
File: 1473827539441.gif (2MB, 320x240px) Image search: [Google]
1473827539441.gif
2MB, 320x240px
>>59751981
>
>>
>>59752027
He asked a question, he got a correct answer. Thats more than most people manage on /g/
>>
>>59751969
Probably going to learn about principles of abstract structures that act as containers of objects with different access and modification properties.

i.e. what's the difference between storing stuff in a linked list and storing it in a decentralized queue or some other array-based solution.

If it's a good course you'll learn about foundational things like hash maps, and tree or other graph based structures like heaps.
>>
>>59752024
I don't know I don't have diabetes, don't project
>>
>>59752062
whats being projected and by who? It was just a question
>>
>>59747177
>using cpp for low level programming

What's it like to be autistic
>>
File: Capture.png (16KB, 347x267px) Image search: [Google]
Capture.png
16KB, 347x267px
>>59752046
this is basically it
>>
>>59752078
>can use C/C++ & asm in one place
dont really know how efficiency & convienece are autism 2bh
>>
>>59749938
Thak you A lot.
the the 26 year old thing is because the prompt said so. The array thing... I'm not sure actually. I just thought a method I was using was only available for arrays but it isn't.
Lastly I didn't know DateTime existed. I'll use it next time.

>>59750008
Man, That's a lot easier, thanks.
I thought about googling if I can turn a string into a date, but I also thought it was be too complex for me. I'm glad you showed me that.
>>
https://matt.sh/howto-c
^ For writing C in this age.
>>
File: fedoraSam.jpg (77KB, 500x435px) Image search: [Google]
fedoraSam.jpg
77KB, 500x435px
This might sound pretty autistic but whatever, I need some advice.
I've been programming and scripting as a hobby on and off for years. I've used C, C++, C#, PHP, Bash, and JavaScript mostly. I've probably done hundreds if not thousands of exercises and created dozens if not hundreds of little CLI or simple GUI applications that just do one or two things, nothing really useful as most of the things I've made have been done before. I'm not interested in making a career out of programming, but I do want to contribute to open source projects for fun. I've cloned plenty of github repos and tried to read through these big projects but I never really see where to begin when reading through the source files, if that makes any sense. I've watch dozens of videos and read dozens of articles about "How to contribute to open source projects" and what not but none of them have ever explained how to actually understand a codebase. What I'm asking is if someone can refer me to a book, article, or video that might help me understand how to do this. Or if someone can explain simply how they walk through a new application with thousands of SLOC? Maybe even refer me to an open source application that was designed to be easy to understand? I know these projects are the results of hundreds of man-hours and I can't expect to understand them in one day, but where do I even start? Thanks in advance for any thoughts.
>>
>>59751314
The most "correct" would be:
Vector2f Vector2f::normalize() {
auto mag = this->magnitude();
return Vector2f{x / mag, y / mag};
}

In general, storing the magnitude in the vector is a pessimization. Most of the time, you won't use it, and you'll be bloating your data which means 50% more reading from main memory. If you do want to precalculate it, store it outside of the vector yourself and do v/m to get v.normalize().
>>
File: anal beads.png (5KB, 673x53px) Image search: [Google]
anal beads.png
5KB, 673x53px
>>59752254
It's worth noting that you can allow the user to try put in the date however they want.

See screenshot; Convert.ToDateTime is pretty flexible and does some magic depending on the system locale, too.

You could try to parse it however they try, then if they fuck up, let them know how they can put it in. Example:

WriteLine("Write your date of birth.");
DateTime validDate = DateTime.Now;

while (!DateTime.TryParse(ReadLine(), out validDate))
{
WriteLine("That wasn't a valid date. Try a standard US format like: MM-DD-YYYY");
}

WriteLine($"You are approximately {(int)DateTime.Now.Subtract(validDate).TotalSeconds} seconds old.");



Example output:
Write your date of birth.
cat
That wasn't a valid date. Try a standard US format like: MM-DD-YYYY
fuck you
That wasn't a valid date. Try a standard US format like: MM-DD-YYYY
seriously?
That wasn't a valid date. Try a standard US format like: MM-DD-YYYY
10-10-1988
You are approximately 898944535 seconds old.


You can add
using static System.Console;
if you're lazy and don't want to type out the 'Console' before your Write/Read calls.
>>
>>59752221
If you're gonna program low level why would you want to all of cpps autism? Why not just use C?
>>
>>59752528
High level abstractions with the power of low level options. With c its just low level tedium
>>
Is unsafePerformIO safe?
>>
File: 1472955965145.jpg (390KB, 686x1024px) Image search: [Google]
1472955965145.jpg
390KB, 686x1024px
>>59752558
>High level abstractions with the power of low level options
>>
27 year old communist tired of shitty manual labor jobs.

Where should I start my studies in programming so I can be a stay at home programmer and live comfortably doing something I find interesting?
>>
>>59752583
you the 'dora poster from /brit/?
>>
>>59752560
define safe
>>
>>59752560
The programmer must ensure purity. For example, if you have an IO action that allocates some memory, uses it, then frees it, it's pure. This is how ST works.
>>
>>59752558
C++ is explicitly for writing complex code. When your writing low level code you want anything but complex. There's a reason Linus uses c in the kernel instead of cpp
>>
>>59752605
This is more true than I'd like.
>>
>>59752616
For a solo project or even a team project where all the members can be kept in check there's no inherent complexity added.
>>
>>59752608
Not causing hard to track bugs or unexpected behavior.
>>59752609
I'm just printing to the screen and there is no way to pass in something incorrect.
I haven't figured out how to embed IO in my interpreter yet so I'm using this for a while.
>>
>>59752645
The second you start using high level abstractions you are introducing complexity.
>>
>>59752671
No.
>>
>>59752668
>interpreter
what's the AST like?
>>
>>59752671
>>59752675
Local variables are a high level abstraction over registers and the stack, which is more complex?
>>
>>59752675
Yes. Would you like me to explain
>>
>>59752616
>There's a reason Linus uses c
Because hes a stubborn and angry fin
Reading a thousand lines of def guards is awful.
>>
>>59752668
>>59752683
in fact what part are you having trouble with?

you really shouldn't be using unsafePerformIO unless you're writing an array library or something like that
>>
>>59752668
>I haven't figured out how to embed IO in my interpreter yet so I'm using this for a while.
unsafePerformIO is an inappropriate hack. Obviously your interpreter must return an IO action or similar.
>>
>>59752690
What I'm referring to when I talk about high level abstraction is stuff like inheritance, object orientated code, polymorphism etc. He's introducing unneeded complexity in his low level stuff by writing it in cpp. That's my argument.
>>
File: gintama laugh.jpg (77KB, 720x338px) Image search: [Google]
gintama laugh.jpg
77KB, 720x338px
>>59752737
>inheritance
>high level

>abstraction
>oop

>polymorphism
>inheritance or oop
>>
>>59752668
>>59752721
The problem with unsafePerformIO when used incorrectly is that it may lead to execution in an undefined order due to laziness.

>>59752737
>object-oriented programming is bad
Now we're getting somewhere. Good thing you can completely avoid OOP in C++ if you like.
>>
>>59751929
I want to find out where my body has to get energy from the "slower" sources and starts producing lactates
From that you can calculate target heart rates for interval training to increase that threshold and get a better endurance
Too bad the equipment doesn't have BLE and my phone doesn't talk ANT+, setting speed/resistance/weight from an app would be fun
>>
File: 1424571701728.jpg (19KB, 500x500px) Image search: [Google]
1424571701728.jpg
19KB, 500x500px
>OOP co-opted the term "polymorphism" just for its specific brand of subtype polymorphism and ruined everything for normal people trying to communicate
>>
>>59752802
>mutable state
>multiple inheritance
>>
>Get dev job

>Ancient frameworks, no revisioning system, no interest in anything but Tomcat and Classic ASP

>First 3 months, refactor a bunch of stuff, build amazing projects, get a ton of stuff done super quickly

>Boss tells you to slow down, your work is creating higher expectations on everyone else.

>Next year of work is doing the bare minimum

>Because of shit architecture, lazy employees and no resources, you are now doing manual account creations and password resets

>10% of your time is spent actually developing anything

>When you do write code, you are the sole developer, because the other devs are busy resetting passwords, the requirements are handled by a bipolar team of MBAs that just likes to say Yes to upper management, and you have no direction or guidance

>Apply to a bunch of jobs with modern code practices, get rejected from every single one because you aren't a transgender lesbian that knows the new JS framework that came out last week
>>
>>59752802
Dumb frogposter.
>>
File: 1489262492823.gif (929KB, 264x320px) Image search: [Google]
1489262492823.gif
929KB, 264x320px
>>59752802
>dumb frogposter co-opted my complaint and ruined it for sane people
>>
>>59752883
>wants to work a job with modern code practices
>doesn't know modern code practices

Truly, the reasons for you not being hired are a mystery.
>>
>>59752883
who are you quoting?
>>
>>59752883
>transgender lesbian that knows the new JS framework that came out last week
This is the new modern code practitioner. Sorry.
>>
>>59752911
This, learn your ass some React.
>>
>>59752883
>Boss tells you to slow down, your work is creating higher expectations on everyone else.
You know you're working a dead-end shitshow if this is the response you get rather than a raise.
>>
@59752883
>that retarded spacing
>>>/r/ibbit
>>
>>59753009 (gatekeeper)
>>
Dear rust meme masters,
What environment are you using? Atom, sublime, vim?
How's the integration with the language?
>>
>>59753212
I've been running sublime, shits gucci senpai
>>
I have another question about visual basic. How can I put the inputs from multiple input boxes into one textbox using a loop? For example, if I wanted a loop that opens 3 inputboxes, I enter one letter into each inputbox, and I want my textbox to contain all three letters. Any help is appreciated.
>>
>>59753212
>What environment are you using? Atom, sublime, vim?
vim
>How's the integration with the language?
>vim
>language integration
>>
>>59753257
texbox4.Text = String.Format ("{0}{1}{2}", textbox1.Text, textbox2.Text, textbox3.Text)
>>
if (A) { 
do_A();
} else {
do_B();
}

... (later) ...

if (C) {
do_C();
} else {
do_D();
}

This is Repetition of Code! Smelly! Gross!
def if(cond, a, b) { 
if (cond) {
a();
} else {
b();
}
}

if(A, do_A, do_B);
... (later) ...
if (C, do_C, do_D);

There, fixed it! :)
>>
>>59753501
In C this is just:
A ? do_A() : do_B();
C ? do_C() : do_D();
>>
>>59753501
>what are ternary operators
>>
File: troll-or-retard.jpg (43KB, 604x453px) Image search: [Google]
troll-or-retard.jpg
43KB, 604x453px
>>59753501
pic
>>
last -f /var/log/wtmp | cut -c1-8,40-


This outputs the username and last successful login. However, if I wanted to parse it up so that inbetween the username and the last login there would be a semi-colon, or something similar, how would I do that?
>>
>>59753501
ifte True t _ = t
ifte False _ f = f

...
ifte A do_A do_B
ifte B do_C do_D
>>
Working on modifying Presburger arithmetic to see if it can handle a restricted form of multiplication while remaining decidable.
>>
>>59753603
same
>>
>>59753598
With Church encoding this is just:
A do_A do_B
C do_C do_C
>>
>>59752780
well that actually sounds worthwhile, im surprised you posted it on /g/
>>
File: 1485807540319.jpg (31KB, 456x465px) Image search: [Google]
1485807540319.jpg
31KB, 456x465px
>>59753603
>>59753612
same
>>
>>59753212
Emacs
It's good, rust-mode, cargo-minor-mode, racer and flycheck-rust. Racer, specifically company, can kill emac performance though I've seen. Not sure if there's a special setting I need to configure to make it more efficient.
>>
File: 1200px-Julia_prog_language.svg.png (43KB, 1200x811px) Image search: [Google]
1200px-Julia_prog_language.svg.png
43KB, 1200x811px
Does anyone know a good book/resource for learning Julia?
>>
>>59753212
VSCode is good. I don't use the tools like racer or flycheck but the Rust extension has integration for them.
>>
my programming group partner just referred to his computer as his CPU
>>
My professor wants us to find a problem that could use parallelism, and that hasn't been done before. How do I find something like that... Where can I start looking?
>>
>>59753459
Thanks, but my problem is that the letters are in inputboxes, not in textboxes. I need a loop that opens 3 different inputboxes one after the other and then puts them all into a textbox.
>>
>>59753760
Your partner is right. A computer is just a fancy box around a CPU. The only goal of a computer is for coding and computation.
>>
>>59753776
Good luck doing anything useful without memory or I/O modules. Unless you're gonna now claim that a SoC is a CPU.
>>
>>59747138
Is this a good way to force a struct to be a certain size?

union
{
char desired_size[32];
struct{
[...]
} useful_data;
} bytefield;
>>
>>59753776
I wish he were just really autistically smart. I'd post his version of the classes we need for our project but I deleted them as soon as I saw them because I literally couldn't do anything with them
>>
File: haifuri sicp.png (611KB, 1280x720px) Image search: [Google]
haifuri sicp.png
611KB, 1280x720px
>>
>>59753792
A terminal is just a fancy device to interact5 with the CPU.
>>
>>59753804
>top cover is on the back of the book
>>
>>59753833
Terminals connect to mainframes, and mainframe computers aren't just CPUs. They need memory and I/O modules.
>>
>>59753793
You can use a union.

struct mystruct_s {
... /* who knows how long */
};

typedef union {
struct mystruct_s s;
unsigned char padding[512];
} mystruct;


This will ensure the union is 512 bytes or more.
Then, you can ensure that it is no more than 512 bytes using a static assertion somewhere in your code:

/* Causes a compiler error if sizeof(mystruct) != 512 */
char array[sizeof(mystruct) != 512 ? -1 : 1];
>>
>>59747413
According to this, I think I am at least 3/4 to employability.
How would one get a programming job?
>>
>>59753871
But what is the end goal? Computation my dear anon. A computer is for computing.

>checkmate
>>
>>59747467
kek, he's talking about HTML colors.
>>
>>59753884
humans are just brains
>>
if the opposite of "pro" is "con", then the opposite of "progress" is what?
>>
>>59753910
No.
Invalid analogy.
>>
>>59753884
And a computer is more than a CPU.
>>
>>59750873
Of course you did, it was the end of the post.
>>
>>59753919
con-gratulations, you're a cunt
>>
>>59753919
regress
>>
>>59753919
ungress
>>
>>59753969
Can such a thing apply to programming though?
Even if you're starting over or redoing something, its still progress
>>
>>59754001
you could redo them worse than before you started
>>
>>59753910
The brain would be the processors and memory. The CPU would just be, say, the frontal lobe. The nervous and motor systems are I/O modules. The rest of the body is the case, power supply, etc.
>>
>>59754001
creation from destruction
>>
File: New PM595 PLC.png (1MB, 2081x1092px) Image search: [Google]
New PM595 PLC.png
1MB, 2081x1092px
>>59754029
Is human a PLC?
>>
Hey /g/als, anyone understand lua?
I want to implement this https://lethalman.blogspot.com/2013/03/controlling-audio-volume-in-awesome-wm.html
but I have no clue where to declare these functions. I only know basic C sadly.
>>
>>59753941
So? That doesn't tell you anything about my reading order.
>>
>>59754152
>Start by defining the following in your rc.lua
https://awesomewm.org/doc/manpages/awesomerc.5.html
>>
>>59754161
Retarded be must you then end the from read you If.
>>
>>59754218
I just put them at the start of the file? Do I need to prepend "local" to them?
>>
>>59747156
*gets no users*
*obscures*
>>
>>59754241
It just so happens that I actually am.
>>
What are modern alternatives to the original lint? <https://en.wikipedia.org/wiki/Lint_(software)>
>>
Be straight with me, is investing time in Common Lisp a bad idea?
>>
>>59754333
Using a language with a good type system.
>>
>Lisp
worst programming language fanbase bar none
>>
>>59754374
I like C, I'm not here to ask for alternative languages.
>>
>>59754420
There, that was hard
https://en.wikipedia.org/wiki/List_of_tools_for_static_code_analysis#C.2C_C.2B.2B
>>
>>59754360
Depends, it a good investment for fun but not for getting a job.
>>
>>59754455
>not being self employed
pajeet pls
>>
>>59754440
Yes, I've seen this, but which one is the best?
There's splint, but it hasn't been updated since 2010.
>>
>>59754490
No idea which one is best, but most editor plug-ins seem to rely on clang these days.
>>
>>59754333
Compiler warning flags.
>>
>>59748078
look up
goto fail;
>>
>>59754379
That's hardly relevant, the language itself is garbage.
>>
>>59754553
Those are not enough, I'm afraid.
>>
>>59754455
what do I invest for a job
>>
>>59754590
Weverything
>>
>>59748045
At least write
if (n <= 1)
return false;
if (n % i == 0)
return false
if (isPrime(p))
primes.push(p);
/* etc. */
>>
>>59754455
even as a hobby, you'd be using a super cluttered old (meme) language when you could at least be using scheme/clojure, it's the opposite of fun
>>
>>59754601
Is that a real gcc option? I use
-Wall -Wextra -Werror -pedantic -pedantic-errors -ansi
>>
>>59754653
No, it's a clang option.
>>
>>59752285
>The first rule of C is don't write C if you can avoid it.

This upsets me. What else am I supposed to write in? C++/Rust are too complex, especially C++. Java/C# take control away. *Lisps have no support, slow, take control away. Erlang/Haskell take control away and make you convoluted your design into some FP allowed design.
>>
>>59754720
Forth.
>>
>>59754634
if ((n <= 1) ||
!(n % i))
return false
if (isPrime(p))
primes.push(p);
/* etc. */
>>
>>59754720
>takes control away

if you want 'full' control, then you're going to have to deal with the complexity that comes with using low level languages.
>>
>>59754720
Clojure.
>>
>>59754720
>Wants full control
>Doesn't want to learn Ada or C++
Don't know what you want, tbqh
>>
>>59754826
>Lisps have no support, slow, take control away
>>
What is man supposed to use when there's no good statically typed and compiled language?
sml
>no good implementation
ocaml
>shittier sml
lisp
>too verbose
c
>decent but memory management slows down prototyping
sepples
>convoluted cluster fuck no sane person would use
rust
>used by nobody, shilled by crazy people, tries too hard to be uglier than sepples
any jvm/clr language
>requires huge vm
d
>can't decide if it wants gc or no
>>
>>59754720
Use C++, but only the parts you want to.

Even C++'s creator says the way he wanted C++ to be was for people to pick and choose what parts of it they wanted, not expecting people to know/use it all[1].

Personally I still write mostly C code when using C++ but with the addition of classes, namespaces, and clojures.

[1] https://www.youtube.com/watch?v=KlPC3O1DVcg&t=1s
>>
>>59754908
>decent but memory management slows down prototyping

Just do what I do and never free in prototypes.
>>
>>59754896
>no support
You have access to the whole Java ecosystem.
>slow
The JVM is fast enough for most applications.
>take control away
If you want to do pointer arithmetic, you're out of luck.
>>
>>59754908
what is this from again?
>>
>>59754908
guess you make your own language
>>
>>59754908
The one I'm making.
>>
>>59754908
swift?
>>
>>59754908
lisp is not verbose
>>
>>59754908
haskell
>>
>>59754989
There are more programming languages than stars in the universe and none of them are good...

>>59755010
apple shit

>>59755013
(let ((x (make-vector 5)))
(setf (aref x 0) 10)
x)

vs

int x[5];
x[0] = 10;
>>
>>59752078
>What's it like to be autistic
Autistic people don't have conscious experience. They're P-zombies. Being autistic isn't "like" anything.
>>
>>59755040
You can just write a C dsl that converts your C code to Lisp, all the benefits of lisp + not being verbose.
>>
>>59754908
Depends on the requirements of your project.

Do you want simple projects and having pre-made libraries for everything? Use Python.

Do you want to optimize or manage memory directly? Use C.

Do you want to further optimize or program for old systems? Use Assembly.

Do you want to use C but you have lots of things using memory dynamically? Use C++.

Would you use C++ but you are concerned about having memory leaks? Use C# or Java.

I have no experience nor interest in other programming languages, so I can't tell.
>>
fuken comoputers
>>
File: 1485584301229.gif (2MB, 400x225px) Image search: [Google]
1485584301229.gif
2MB, 400x225px
>>59755038
>unsound type system
>>
>>59755298
>all those other languages
>>
>>59755038
>generates garbate 1gb/s
>>
>>59755318
every single one of those languages has an unsound type system as well.
>>
>>59755207
>Do you want simple projects and having pre-made libraries for everything? Use Python.

I use C# for this particular case.
>>
>>59754751
They are separate, see the original code (the one that the person I quoted quoted) and you'll understand why. I'm not that dumb.
>>
>>59754958
the madman!
>>
>>59755207
>Would you use C++ but you are concerned about having memory leaks? Use C# or Java.


Both c# and Java can memory leak if you create patterns that confuse the GC
>>
>>59747138
I'm parsing an XML file at work. There are many different subsections in this XML. I'm utilising Python and so far have got a series of these:

for cov_data in xmltree.iter('coverage'):
for cov in cov_data.iter('function_name'):
for coverage in cov,iter('data):


etc etc. Is there a way to condense this down, or is this the best way?

Another task I need is to parse a file and pull out the function name from a line. So I know that the name is on it's own line with:

--C function under test: <function_name>

I want to pull the <function_name> out from the file.
>>
>>59755396
How can a GC get confused? It isn't sentient.
>>
>>59755400
seriously use a string of list and a stack to do that
>>
>>59755400
AYOOO HOL UP

import xml.etree.ElementTree
e = xml.etree.ElementTree.parse('thefile.xml').getroot()
....
>>
give me good ideas for a project
>>
What's the importance of freeing memory other than leaving space for other things in your RAM?
For example, here, would 20 bytes really make any difference?
char *m = malloc(20);
/* ... */
free(mallocd_memory)


Also, what's the importance of freeing FILE pointers if the files are open for reading and not writing? It's possible to have multiple (FILE *)s open for the same file at the same time if they are read only ("r"), so why do
fclose()
?
>>
>>59755439
Given two strings A and B, write a program that determines if A is a substring of B. Optimize for speed and space.
>>
File: bait-this-is.jpg (216KB, 798x604px) Image search: [Google]
bait-this-is.jpg
216KB, 798x604px
>>59755452
>>
>>59755396
That's an oversimplified explanation. You can't "confuse" the GC, rather you are confused yourself and you think that something is unreachable when it's not.
>>
>>59755417
Unfortuantely, I can't get lxml.

>>59755433
Any documentation to go with this? Once I have the root how do I traverse the rest of it?
>>
>>59755465
B.contains(A)
>>
>>59755439
Write an anime language which you will then use to write another anime language.
>>
>>59755473
>Any documentation to go with this? Once I have the root how do I traverse the rest of it?

for atype in e.findall('type'):
print(atype.get('foobar'))


and so on
>>
>>59755473
You have everything. Just factorize your code.
>>
>>59755452
>
free(mallocd_memory)

I meant
free(m);

I fucked it up by changing variable names.

>>59755470
No, I'm really serious.
>>
>>59754908
you accept that no language is perfect and use Java.
>>
>>59755416
Mien is, her name name is ashley and she can't handle me sometimes.
>>
>>59755483
> Optimize for speed and space.
nice try tho
>>
>>59755488
Ah, that won't work. Because the function under test is in the XML file 4 times under different sections.

I want to get the results from the detailed section.
>>
>>59755494
>No, I'm really serious.
If you're serious. Stop coding anon. We have already to many code monkeys. We don't need more.
>>
>>59755495
someone stuck up on languages like that is a telltale sign of a novice anyway. no point in giving suggestions.

a real programmer can easily adapt any language to their needs.
>>
>scan-build: No bugs found.
feelsgoodman
>>
>>59755510
Im confident that the nerds at sun already did that
>>
>>59755517
what bout

XML:

<data>
<items>
<item name="item1"></item>
<item name="item2"></item>
<item name="item3"></item>
<item name="item4"></item>
</items>
</data>

PYTHON:
from xml.dom import minidom
xmldoc = minidom.parse('items.xml')
itemlist = xmldoc.getElementsByTagName('item')
print(len(itemlist))
print(itemlist[0].attributes['name'].value)
for s in itemlist:
print(s.attributes['name'].value)

OUTPUT
4
item1
item1
item2
item3
item4
>>
>>59755452
If you do it once, there is no practical problem; but if you malloc in an infinite loop you will have an ugly memory leak.

But anyways, do and obsess with it, or else you won't be used to it when working in a bigger project and you will wonder why your program is using 2 GB of RAM when calculating the sum of the prime numbers lower than 2 million.
>>
>>59755532
I'd be more concerned about logic bugs that the scan didnt catch
>>
>>59755452
Lots of tiny memory leaks add up to a big memory leak. With file handles it's a permissions issue. If you leak a file handle, even if it's read-only, nothing else will be able to open the file for writing.
>>
>>59755526
>a real programmer
what's a real programmer? someone who is not faking it?
>>
>>59755525
>to many
We already have too many assholes in this thread, if you don't want to help, then shut up.
>>
>>59755452
>For example, here, would 20 bytes really make any difference?

Very little for a toy program that has a short lifetime since your OS will clean up after you.

> what's the importance of freeing FILE pointers
so that the OS knows you aren't using it anymore and don't lock it up, but then again in a toy program it doesn't matter too much and OS can clean up after you.


Likewise for sockets, but if you've ever noticed a socket was unusable for like 30s-1m after your program closed it was likely because the OS didn't clean it up yet making future runs fail until ti does.


tl;dr in toy programs it doesn't matter much on a good modern OS. Anything long-running or complex you'll start to see problems especially if you keep allocating memory and never freeing.
>>
>>59755556
someone not obsessing over the minutiae of a language and instead gets shit done because they're a fucking boss.
>>
>>59755544
I sort of have this:
<data>
<cov_summary>
<item name="item1"></item>
<item name="item2"></item>
<item name="item3"></item>
<item name="item4"></item>
</cov_summary>
<cov_detailed>
<item name="item1"></item>
<item name="item2"></item>
<item name="item3"></item>
<item name="item4"></item>
</cov_detailed>
<cov_statements>
<item name="item1"></item>
<item name="item2"></item>
<item name="item3"></item>
<item name="item4"></item>
</cov_statements>
</data>


I want to get the information on the items in cov_detailed
>>
How hard would it be to write something that hooks into 4chan X and filters posts using e.g. a neural network?
>>
>>59755556
Someone who doesn't use Pascal.
>>
New thread:

>>59755577
>>59755577
>>59755577
>>
>>59755548
>but if you malloc in an infinite loop you will have an ugly memory leak.
What would be preferable
this:
char *text = malloc(TEXT_SIZE);
for (i = 0; i < n; ++i) {
fgets(text, TEXT_SIZE, f);
/* do something with text */
}
free(text);

or this:
for (i = 0; i < n; ++i) {
char *text = malloc(TEXT_SIZE);
fgets(text, TEXT_SIZE, f);
/* do something with text */
free(text);
}

?
in the second form, the free() call may not necessarily be in the same function.
>>
>>59755723
>in the second form
I meant the first.
>>
>>59755723
Please check for malloc return value filthy code monkey.
>>
>>59755785
This is just an example, not an actual program, so chill out please.
>>
>>59755723
always use calloc over malloc.
>>
>>59755842
Don't use calloc. It's not standard C.
>>
>>59755842
Absolutely stupid.
>>
>>59754958
this. Its a prototype, its there to prove out a concept and should be thrown away. Didn't think I'd ever say this but sounds like poster want him a C
>>
>>59755842
calloc(a, b)
is just
malloc(a * sizeof(b))
>>
>>59755856
what?

>>59755859
The use of non-zero'd memory has led to many hidden bugs in C programs over the years. May I refer you to https://matt.sh/howto-c


>>59755888
I suggest you reread what calloc does my friend.
>>
>>59755926
>The use of non-zero'd memory has led to many hidden bugs in C programs over the years.
So accessing not set memory is good pattern. No the problem is code monkeys only.
>>
File: 1461021781313.png (65KB, 1376x747px) Image search: [Google]
1461021781313.png
65KB, 1376x747px
>>59755856
>>
>>59755926
>I suggest you reread what calloc does my friend.
That and initializing everything to zero.
>>
>>59755319
>not having enough ram
>>
>>59756099
I didn't have enough so I downloaded a couple terabytes (it took forever to finish the download), and now I have more than I will ever need.
>>
>>59756099
>our language is so shit you need to buy better hardware to use programs made with it
Might as well just go full javascript
>>
>>59756169
if you can use resources, why not use them
haskell is useful and doesn't make me wanna kill myself, so...
>>
Am I the only one here who has problems reading pseudocode? I am reading a book using pseudocode, and man, am I having trouble understanding.
>>
Rereading some of my textbooks and rolling through misc programming challenges to build some sorta git portfolio, cause holy shit, do I need to find an actual job somewhere. Gigs help, but real cashflow is godsend.

Any of you guys know if a decent topcoder ranking or similar actually translates to anything meaningful for hire-ability bonuses?
I'll probably still go through the paces, cause ay practice, but I'm still curious.

>>59756997
Try drawing diagrams/flow charts?
>>
>>59753768
anyone?
Thread posts: 345
Thread images: 25


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.