Hardest Algorithm or Project you have had to write

Hey Sup Forums, tell me the hardest project or algorithm you have ever written.

Other urls found in this thread:

pdfs.semanticscholar.org/5f32/9a27f6943207f69d8056344b95cedba054d2.pdf
twitter.com/SFWRedditImages

I made a turn based tactics game with a zillion lines of code and half of it was XML data for all the units and levels, AI scripting etc. shit.

So did I, but I used JSON. What kinda stuff?

A character planner for Fallout 3.

A fucking POSIX 2001-3 PAX Tar implementation. Yes, I'm bad.

Finding the shortest path in a graph in linear time.

That sounds painful.

Sounds really difficult, don't beat yourself up

What algorithm?

For my networking class we implemented a version of TOR (we called it Tor61 if you want to look into it). I implemented it in node.js which actually wasn't too bad DESU. In hind sight it was a great learning experience.

Plain XML, did not need any advanced features.

removing the .active css class from a navigation link and adding it to whatever one was clicked by the user

Well, as a freelance programmer the most advanced program I've written until now is an all in one register program for small grocery stores. It's got everything a small grocery store could need, for €2000 I install it on the PC, for €5000 I install the equipment too, for €10000 I'll get everything you'd ever need in terms of IT set up. If a store owner wants more, I charge more.

A pyramid of *

I meant in terms of the game.

That's pretty cool Dave

Hardest thing I've ever worked on is mpv's vo_opengl

A text to pictograph conversion system and a text classification pipeline for suicidal post detection.

I managed to even fuck up the name, its POSIX.1-2001/pax lol shit. This is the chesksum calculation logic and some of the header parsing

> fizzbuzz
couldn't find a library to do this

>one gigantic piece of shit monolithic java blob
you're the one making this hard on yourself

You could have commented the code a bit better desu

Same, but with # so it was a bit easier

There is no simpler and cheaper way to do it. Trust me. Read the PAX specification and ustar specification, its a fucking mess. + everything is in octal

You could have written it with more functions honestly couldn't you?

that screenshot gives me terrible flashbacks to a job where we were only allowed to share code by taking screenshots and we made backups by printing off screenshots

some shitty web app

What, why?

>
I did in the initial implementation, that was a clusterfuck and it did not support pax. This shit is alreay 1000+ lines long, tried to slim it down and prevent calling functions over and over again. This is basically splitting a 512 items long byte array into smaller ones and stores them into a 2 dimensional array. Later i parse the smaller arrays into ASCII and read them or parse the bytes to octal ascii and then to a decimal integer. Its a mess. Dont ever try to implement that shit.

>java
kek
use C phaggot

Invert a binary tree

No thank you, i like my errors in a stack trace

>not using a debugger that does that + more
i bet you take it up the ass too faggot

I wrote a program that returns the first n prime numbers. Was tough, took me a week.

Sounds a bit odd, but 1k lines?

working with the youtube api

wasn't meant for

Meh lying, round 730 w/ light javadoc

An OS that takes advantage of multiple cpu cores

...

Not me, but It took my friend 4 months to implement dijkstra's algorithm and when he was done it still had errors.

>What algorithm?

He's baiting, he'd be a millionaire if it was possible.

Didn't read the linear time bit.

This probably wins

>camelCase
gross

Basically anything which involves transformation matrices. Too easy to screw up the order.

>unironically using snake_case

it's 2016 user

>not camelCase
Absolutely disgusting.

For tensors?

I use WhateverThisIsCalledCase

>starting a variable with a capital letter

Absolutely disgusting

ALLCAPSNIGGERFUCKSPACES
I bet you don't linearize your braces and parentheses.

But that's for Class names faggot

>he has never debugged C in his life

Invert in what sense? Largest to smallest and switching the order? What exactly is the process for that? I guess it depends on how much of the hard stuff you gotta do yourself.

>Basically anything which involves transformation matrices. Too easy to screw up the order.
I feel you. is mostly working with affine transformations, except there are a lot of them, the order of them is unclear, and interacts in nontrivial ways with sequence points.

mirror most likely

>recursion
just fuck my shit up. i can trace them but not write them

I made a 3d physics simulator with accelerated spatial queries.

Also a made an inverse kinematics for my 18 DOF hexapod.

i had to make a radial-denominating inverter library for processing and analyzing gene samples geometrically

since the machine they were using to get the samples failed to gather binomial tendencies they wanted it done without using matrix sublevel arrays so you can imagine my struggle i'm sure

I understood some of these words

Well, you aren't gonna get better until you do them more

I've written software to emulate older CPUs, cache coherence simulations, router simulations, made use of neural networks for small fun projects, written multiple compilers for java-like languages, written DSLs in common lisp, and many more, but... but the hardest thing I've ever had to do was fix someones broken javascript code for some simple game of checkers.

I completely choked on it and worst of all the guy stored the board as just bits embedded in a int and displayed them as hex values and was asking me on the spot to give the hex values meaning and shit and I just completely choked on it and couldn't manage to decipher how he set it up in the first place making it nearly impossible for me to fix it for him. So I told him I was not the right guy for him and I'd rather kill myself.

That's retarded, didn't he know arrays were a thing?

You are lying, it's nonsense.

I'm sure he did, but he probably set it up in a way to see how you would think, or if you're an autist.

You are lying, it's nonsense.

why

Point cloud splitting into layers of thickness n
Then interpolating a closed spline in each layer - treating it as a plane.

Weseled my way out of using non-linear differential equations with using savitzky golay filter and then a normal spline with node at mth point.

A vidya I wanted to autistically program using only C++ and SFML, which degenerated in an all-purpose game engine with neat shit like deferred rendering, materials, GUI Manager and such. It wasn't that hard, but it reached a certain degree of complexity, and wasn't even halfway complete.
Development halted because fuck everything, I needed to pass some exams.

I'm gonna build a doom-like 3d demo thing with a simple map editor

how to do primitive java graphics (I'm thinking "drawLine();") in a java application (not an applet)

cairo?

I took three graduate-level CS courses while getting my masters... Compilers, Artificial Intelligence, Interactive Computer Graphics (c++ & openGL).

Compilers final was an ANSI C compiler, written in C, which had to be able compile itself (to earn an A). No one achieved it in my year, we all got Bs for compilers which worked on all the example cases but not their own source.

AI final was a negamax solution to either Checkers or Othello. Students with the best-performing AI for each game (against each others', and the professor) got an A. Everyone else got B or below. Our year, two Othello AIs were tied pretty close so we had a class record, 3 As instead of 2.

Computer graphics final was a Rubik's cube. Draw cube in 3D, allow player to make (and undo) any moves, and check for completion. This was the easiest of the 3 and the only one of those 3 classes I got an A in, but still ended up being a huge program and time sink.

>This was the easiest
this sounds like a lot of work. maybe from my newbie perspective.

how long have you been programming? did you learn everything in college?

I'm surprised you didn't almost always have draws in Checkers. It's a solved game.

My last assignment was A-star too bad I didn't end up getting it right

i once made an automatic stat roller for dnd 5e in my ti-84. i want to get into real progamming but dont currently have a computer to myself.

you will get one. don't worry.

Once, I had to write a for loop that ran a variable number of times.

>I'm surprised you didn't almost always have draws in Checkers. It's a solved game.

not under negamax, (unless you're running it on IBM Watson) there's no way you can tree an entire game's worth of moves from starting position. Same with Othello/Reversi which is the reason they are so commonly used in university AI courses

saving up right now just going through moving and getting some extra money in the bank to deal with emergencies. you wanna hear my memer part plans? (and judge me hard as fuck i presume)

go ahead. the only thing we have here is time

Chinook solved it negamax with alpha-beta pruning.

pdfs.semanticscholar.org/5f32/9a27f6943207f69d8056344b95cedba054d2.pdf

It is not pure negamax, but no one has used pure negamax for thirty years.

>IBM Watson
Watson would be remarkably poorly-suited to playing Checkers. It's purely for machine learning. A normal server cluster would be better.

Text recognition based on the intricacies of someone's own handwriting.

node 202 case
gigabyte ga-f2a88xn-wifi
amd athalon 60k
8g ddr3 (dont know what ram exactly yet)
2t hdd (same would love suggestions)
evga 500 watt sfx

idk what gpu to get (thinking $250-300) and need a low profile cooler so i can oc my cpu.

for my upgrade plans im thinking more ram and an ssd,

>Rushabh Mehta

poo_in_the_loo.jpg

I would switch the CPU to a Jewtel, and get yourself an AMD GPU.

>Jewtel
im trying to SAVE money not spend extra. for a similar chip it would be +200 so no thanks.

>get yourself an AMD GPU
thats what i want. i want 40-60 fps 1080p on med settings. but dont know what card to get.

lel, hackerrank?

>Chinook solved it negamax with alpha-beta pruning.
>Watson would be remarkably poorly-suited to playing Checkers.

ok sorry Sup Forums

s/watson/chinook/

you know there is an :active selector right?

>making students compete against each other for a predetermined number of A's

u are full of shit

>AI final was a negamax solution to either Checkers or Othello
pretty cool, for mine we just did minimax and a-b pruning on 3d tic tac toe, was cool, but looking back i could do negamax too, but he wanted minimax specifically

OS design and file system design

>mfw trying to create a mkdir or rmdir that wouldn't destroy my inodes
>mfw trying to test IO redirection and the files being instantly corrupted when using cat f1 > f2

I passed both glasses but never fixed that shit lol

processing for java

>I passed both glasses
you might need glasses

>but never fixed that shit lol
honestly if you give a good enough effort that's good enough for most things, i guess a lot of profs just want you to show considerable effort to implement material rather than just go through the motions

engineering colleges, man

>we just did minimax and a-b pruning on 3d tic tac toe

this is a really neat problem, with a well-defined solution space
probable avoids many of the hellish edge-cases my Othello AI had to deal with.

ours also required alpha-beta pruning;
negamax is very similar to minimax and is really just a special case for zero-sum or constant-sum games

buy intel, dude. even on a budget.

>i guess a lot of profs just want you to show considerable effort to implement material rather than just go through the motions

this prof in particular cares if you work hard on it. I went to his office every day for weeks to fix my shit especially when my OS wouldn't swap from kernel mode to user mode.

I guess he assumed that if you worked hard on this shit you earned the grade. He was a nice prof and probably one of the smartest I have ever met in my life.