[ / / / / / / / / / / / / / ] [ dir / animu / colombia / hypno / leftpol / mde / tacos / vg / zoo ]

/prog/ - Programming

Programming board

Catalog   Archive

Posting will disabled for a few hours on September 21 from 0400 EST while we migrate our database to INNODB. Hardware upgrade downtime is still TBA.
/d/egenerates
August 2018 - 8chan Transparency Report
Name
Email
Subject
Comment *
Password (Randomized for file and post deletion; you may also set your own.)
* = required field[▶ Show post options & limits]
Confused? See the FAQ.
Options


82e3e8  No.5212[Reply]

Is there anything about x86 ASM? I want resources on x86 ASM. Does anyone here have any good books or have experienced programming in it.

1 post omitted. Click reply to view.

b981e2  No.5215




bca91f  No.5136[Reply]

Discuss and share Pascal related talks here.

This includes all variations (for now), but specify which one you're referring to.

3 posts omitted. Click reply to view.

23dabd  No.5211

program answer;

const pascal = shit;

begin

write('Pascal is ', pascal)

end.




92ebfa  No.5133[Reply]

Discuss and share C related talks here. K&R, Ansi/ISO, C99, C11, embedded are all welcome.

10 posts omitted. Click reply to view.

11648e  No.5208

>>5166

It seems these videos aren't available anymore.

I'll check youtube though.

*2 secs later*

Here they are: https://www.youtube.com/playlist?list=PLpIxOj-HnDsPZIJYO4U9f-xRI8bBadaso

By the way, did anyone read Modern C by Jens Gustedt? I'm a scrub (EE freshman) and found that book unapproachable.




57c9b4  No.5138[Reply]

Discuss and share Python related talks here.

This includes all versions just be explicit about it.

1 post omitted. Click reply to view.

a9deb7  No.5196




152758  No.5134[Reply]

Discuss and share C++ related talks here. All early and later standards are welcome.

16 posts omitted. Click reply to view.

6d1bbc  No.5181

>>5180

>Why does the "greatest language in history" have pointers _and_ references?

You can't reassign a reference.

>C array, std::array, _and_ std::vector?

C array for C compatibility. std::array is stored on the stack.

>No algebraic data types?

There are. It depends which ones you want. You have std::variant in c++17 for sum types, but pattern matching admittedly still sucks, depending on operator overloading. If you want something better in this field, Rust or D are better choices.

>No GC?

Bit every language needs GC. We still have a need for non-GC languages and C++ is a part of that set for a reason.

>A compilation model from the 1970's which to this day limits the way you structure your code, and required header guards?

This does suck. It's that way because of history. Modules will make it better, whenever the fuck they finally land.

>A context-sensitive, undecidable grammar which makes it impossible to write a compiler that is not slow as molasses?

History. C++ parsing sucks because of decades of old shit that isn't needed anymore and a template language that's a convoluted mess.

>Incomprehensible template errors when you miss something as trivial as a semicolon?

Clang does better than g++ here.

>No standard networking library?

On the way eventually.

>The very concept of rvalue references, perfect forwarding, and RVO which no other language has to worry about?

Historical shit.

>Two separate attempts at implementing smart pointers which arPost too long. Click here to view the full text.




406df8  No.5137[Reply]

Discuss and share Fortran related talks here.

This includes all variations (for now), but specify which one you're referring to.



dc5b95  No.5135[Reply]

Discuss and share HolyC related talks here.

Important: Stay only on the subject of HolyC only. Terry is wonderful but nobody seems to ever focus on his work. This will try to fill that gap.

Some documentation: https://web.archive.org/web/20170531043554/http://www.templeos.org:80/Wb/Doc/HolyC.html

Post last edited at


fafeb9  No.5129[Reply]

New settings for this board will slowly be implemented. More changes to come.

* imgs will not be allowed.

* Languages will have their designated areas and are only used by people who are already familiar with the language to some degree. "New to programming" users refer to the solid foundation sticky or elsewhere on the internet/8ch.

* Asking "how do I start or what language should I learn?" Is not allowed and will be removed/ignored. Do some research and google those questions yourself because we cannot afford to answer the most redundant questions on the internet here anymore. More people ask those questions alone on the internet than the number of people who die from cancer- good god! I can understand you just want to maybe talk to someone or just needing some attention- that is a path you must walk alone chosen one.

Once you have become more familiarized with language (or are already) point your question to the appropriate language/thread sticky.

Other threads will be for personal projects or challenges you may want to bring up?.. And try to keep it original :) Other purposes will be added here later.

Finally I don't want to hear any complaints about other users or programmers in general or "my language is better"/other smug-cringy comments. This just gets conversations off the tracks and brings up emotions unchained. We don't need any more sissies here.

Sharing resources on good materials will be ideally posted in dedicated thread- but not required. If worthy enough it will be included in the respective language's first post.

Teach yourselves some self-restraint and try to be respectful to each other (not required but always appreciated)

Post last edited at


File: 1439697368517.jpg (179.29 KB, 480x710, 48:71, 9780262019347_0.jpg)

c71b16  No.3034[Reply]

This guide assumes you forgot everything from highschool. No you don't have to learn any of this in order to program you can just start hacking around every .c file in your kernel.org git source clone and see what happens. Why would you want to learn math? Because it will change your thinking. You won't be easily fooled by bullshit, you will have tools to sort through obvious logical fallacies. You will be able to optimize programs and create your own algorithms. You will be able to estimate. Above all, you will be able to solve problems using computation which is what computer science is all about. And least of all, you will get paid more than anybody else without this knowledge so if your goal is shekels then read on. Note: DO THE EXERCISES. You won't learn otherwise. Books instead of video lectures were chosen because they've lasted 30+ years some of them in relevancy in the field, also lectures disappear all the time like when MIT nuked all one prof's Physics OCW lectures because he tried to pickup a student, setting a precedent that at anytime this information can disappear. Read a book nigga.

Math Preliminary

Basic Mathematics by Serge Lang

Buy/Pirate this book (he's dead). It's highschool math, from the perspective of a Mathematician. You will learn up Pre-Calculus and be prepared for rigorous proofs later.

An Introduction to Mathematical Reasoning" by Peter J Eccels

This changes you from rote drilling and being a human calculator in highschool to learning what math actually is, and what proofs do. Excellent, excellent book.

How to Solve It by G. Polya

How to do proofs, written in 1940s and still for sale in every Chapters/B&N bookstore to this day because it's the best proof helper that exists.

Welcome to Proofs

Calculus" by Spivak

Actually, you are learning ANALYSIS, in addition to calculus. Torrent the 3rd edition w/the answer book. This is a fucking hard assed book, you may be bePost too long. Click here to view the full text.

240 posts and 19 image replies omitted. Click reply to view.

9a7338  No.5089

>>5087

Hey! I am more and more convinced that there is no such thing as a shit idea, because execution is what really matters. Lots of successful products, lots of famous apps came from ideas that were already implemented, but badly - or not good enough.

Personally, I liked your post on 4/sci/ and I think your idea has got potential. The only major drawback is that people are lazy, they don't follow through their plans, not many are really committed to their goals, and thus a study related app that really works can only be aimed at that niche of people that are already trying to do something.

Maybe we can really do something about it.

But in the meantime, what are you trying to study (except Spivak, I guess) and would you like to finally start attacking some book together?




File: 1411372549161.jpg (64.52 KB, 447x553, 447:553, 23456456789.jpg)

706e1e  No.60[Reply]

Does /prog/ need images?

http://strawpoll.me/2622392

Also you can suggest changes (rules, dashboard).
72 posts and 4 image replies omitted. Click reply to view.

2cf9ec  No.4767

more textbrowser-friendly sites will go a long way toward reducing internet cancer levels




6d99f8  No.1351[Reply]

RULES

No advertising.

Stay on-topic.

No questions like "can someone do my homework?".

Use code tags for code and $$ for math.

No shitposting.

Don't do anything that requires to add more rules.


http://8ch.net/prog/rules.html
1 post omitted. Click reply to view.
Post last edited at

6d99f8  No.1359

>>1351
If you want to contact the admin of this board you can send a mail to prog@8chan.co



98fb41  No.5200[Reply]

Boy I sure wish I could do something like if(x != (1 || 2 || 4 || 8 || 16)) instead of if(x != 1 && x != 2 && x != 4 && x != 8 && x != 16). JUST DeMorgancuck my shit right up fam.

Am I retarded and is there a way to actually do this? Or is C# retarded and can't do logic properly?

5c1a8d  No.5201

>>5200

I don't think you can do that, "1 || 2" is asking whether 1 or 2 are true.

One alternative could be to use a switch, but it isn't necessarily better.

[code]switch(x) {

case 1: case 2: case 4: case 8: case 16: break; default:

// something

break;

}[\code]


5c1a8d  No.5202

>>5201

I'm too fucking tired to fix that code block so deal with it.


4ccdca  No.5216

Python:

if x not in [1, 2, 4, 8, 16]:

stuff

In a good language, you could have just defined some language construct to do what you wanted instead, though.


02fde9  No.5217

>>5216

Use a set for membership testing, ya turnip.


e7a975  No.5218

Easy in ruby as well:

Set[1, 2, 4, 8].include? x

And C++:


static const std::unordered_set<int> membership = {1, 2, 4, 8};
if (membership.count(x)) {

Really, any language with some sort of set membership check. C# has HashSet, so you could use that, though it might be slower. I'm not sure how easy C# makes static const variables, so you might incur extra overhead having to construct a set every time if not, or stick the variable into a higher scope.




1c8f64  No.5213[Reply]

I'm been stuck trying to write a CRC32 algorithm, mainly due to the lack of documentation anywhere… Here is my understanding how how it works…

>use 32 bit shift register, and 32 bit polynomial (technically 33 but MSB is not used for software calculations)

>initialize register to all 1's (or uint.maxvalue)

>shift each input byte into register 1 bit at a time, starting from the LSB

>if the value that gets discarded from register is 1, then XOR the register with the poly

>if not then do nothing for that bit.

>finally after all data is shifted into register, XOR the register (1's compliment), and that's the resulting CRC.

Seems simple enough, but when I actually try running it and comparing it to multiple CRC32 calculators online they don't match my result. I'm certain my polynomial is correct and certain my bitshifting and XORing works properly, I seem to be missing something.

P.s. I know practically all CRC32 calculators use a table of precalculated values, and thus all example programs use the lookup tables. I think its logical to learn how the basic CRC32 calculation works first… But there seem to be zero tutorials or explanations.



000000  No.5184[Reply]

Buenos días mediante la presente busco una persona que pueda ayudarme con un script que permita mediante el regedit mas específicamente "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run" me permita añadir un nuevo registro a un ejecutable .exe ("ACLARO PARA WINDOWS 10" ya que para estos se necesitan unos permisos especiales para el script y los he programdo pero no funcionan ya verifiqué ruta y código), estoy desarrollando algo y me falta esa funcionalidad, otra cosa que deseo es información sobre algún hosting que recomienden para phising pueden comunicarsen al siguiente correo:

frenlich@torbox3uiot6wchz.onion

Deseo aprender y si es posible compartir conocimiento ya que estoy perfeccionando en programación si existe algún grupo sería mejor, agradezco de antemano la atención prestada.

635390  No.5210

>>5184

Aquí se usa inglés. Also that question doesn't go here at all.




File: 1465424386980.jpg (27.58 KB, 500x295, 100:59, basic-2.jpg)

1f513b  No.4269[Reply]

will there ever be another language like basic?

>ships with every computer

>easy to learn easy to use

>can do most simple tasks, even make little games

>was considered the "linga franca" for learning languages

18 posts and 1 image reply omitted. Click reply to view.

cf734c  No.5121

lua. fuck every other language.

its so much better than Bython or Jehovahscript.

luajit which is lua's jit compiler is almost as fast as c.


acb90c  No.5122

>>5121

Luajit is not "lua's jit compiler", it's an alternate implementation of the Lua language that has a jit. At least have a fucking clue of what you're talking about.


cf734c  No.5124

big nerd detected


f99aa9  No.5205

Yes, it's called Javascript.


8ba971  No.5209

Scheme.




Delete Post [ ]
[]
Previous [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14]
| Catalog | Nerve Center | Cancer
[ / / / / / / / / / / / / / ] [ dir / animu / colombia / hypno / leftpol / mde / tacos / vg / zoo ]