E01: What is the FASTEST Computer Language? 45 Languages Tested!

  Рет қаралды 167,454

Dave's Garage

Dave's Garage

2 жыл бұрын

HD Episode 01: Retired Microsoft engineer Dave Plummer takes you on a guided tour of 45 different computer languages and drag races each against one another using a prime sieve benchmark. From Ada to Zig and everything in between, find out which is fastest and which is slowest.
Languages tested in the series include ARM ASM, X86 ASM, Ada, BASIC, Bash, C, C++, C#, D, Dart, Delphi, F#, Fortran, Go, Haskel, Java, Julia, Lisp, Lua, Node, Nim, OCaml, Octave, PHP, Pascal, Perl, Powershell, Python, R, Ruby, Rust, Scala, SQL, Swift, TypeScript, V, Zig, and more are being added!
Each round, languages are tested in groups, such as C vs C++ vs Rust, Python vs BASIC, Ada vs Pascal vs Delphi, and so on.
Github Code: github.com/PlummersSoftwareLL...
I am re-uploading this as the original video appears stuck forever at 306p. My apologies if you received this as a duplicate!

Пікірлер: 852
@kbsanders
@kbsanders 2 жыл бұрын
I can't wait to see the Minecraft Redstone implementation.
@Thisone95
@Thisone95 2 жыл бұрын
I mean you could probably beat the 294 seconds. Would be interesting to see
@d.l.7416
@d.l.7416 2 жыл бұрын
EDIT: turns out i forgot how sieves work and misunderstood the problem, here's the correct version: You only need to be able to do a thing for each prime up to 1000 (sqrt of 1 million) So thats 168 * 6/20 = 50.4 seconds if you can do a thing every 6 ticks (which is possible) And you only need to be able to count to 1000 (because you only need primes up to sqrt(1,000,000) to do the sieving) And that only takes 10 bits. So you only need something on the order of 100 million blocks (exactly how much it is idk). Lag would be a big problem tho. I have an idea which probably works and would be able to run in the theoretical 50.4 seconds on a hypothetical supercomputer, and I'm gonna start making it. (before the edit i massively miscalculated and got 3 days so 52 seconds is a lot better lol)
@user-fc8xw4fi5v
@user-fc8xw4fi5v 2 жыл бұрын
i dont think this would be possible... HOWEVER, i volunteer to write this in MCFUNCTION though
@user-bq9jp7bl5p
@user-bq9jp7bl5p Жыл бұрын
@@d.l.7416 i don't see why you need to find 1 million primes, nor do you need a modulo operator
@d.l.7416
@d.l.7416 Жыл бұрын
@@user-bq9jp7bl5p the test is finding 1 million primes so you need to find 1 million primes. the algorithm is a sieve and sieves require modulo or something as complicated to build in minecraft
@DavesGarage
@DavesGarage 2 жыл бұрын
I re-uploaded this in HD 1080p60 because some folks were only seeing it in 360p. My apologies if this is a dupe for you this morning!
@dogee1985
@dogee1985 2 жыл бұрын
Thank god! Spent half an hour trying to figure out why the video was bad quality
@meanbeach5109
@meanbeach5109 2 жыл бұрын
Seems perfect now!
@deefdragon
@deefdragon 2 жыл бұрын
Worth marking In the titles that this is an HD re-upload, and that the old one is SD only.
@ebol08
@ebol08 2 жыл бұрын
Should remove the other one'
@jackgerberuae
@jackgerberuae 2 жыл бұрын
@@ebol08 no, we will lose the comments
@nattyman0007
@nattyman0007 2 жыл бұрын
Putting the episode number in the video title may be more clear that this is a series. Otherwise, I'm excited to see the whole thing :)
@DavesGarage
@DavesGarage 2 жыл бұрын
Will do for future!
@DavesGarage
@DavesGarage 2 жыл бұрын
Done and done for this one as well. Thanks for the suggestion!
@rayford3430
@rayford3430 2 жыл бұрын
@@DavesGarage Hmmm, Richard Stallman would have numbered it E00 .
@loloknight
@loloknight 2 жыл бұрын
If you could add timestamps that would help a lot! Thanks great work
@acherongoon
@acherongoon 2 жыл бұрын
@@loloknight I actually like listening to Dave's talk, some of the asides are interesting (and funny) -- thanks Dave. Timings would lead away from the stories and discussions.
@jayjacob9621
@jayjacob9621 9 ай бұрын
I really enjoy how you give the history of each language as well as give a quick overview of how each language works. This series was a great idea, thank you!
@Kolor-kode
@Kolor-kode 2 жыл бұрын
This is a great series, could watch it all day. Thanks Dave
@DavesGarage
@DavesGarage 2 жыл бұрын
You're welcome!
@nitrouspeed3583
@nitrouspeed3583 2 жыл бұрын
I bet Dave’s “recreationally fluent in C#” is still on par with the guys who wrote Unity
@Alche_mist
@Alche_mist 2 жыл бұрын
While I really don't bet against (I'm inclined to agree), do you know that the Unity itself was written in C++ (C# is used as its scripting language)?
@nitrouspeed3583
@nitrouspeed3583 2 жыл бұрын
@@Alche_mist I didn’t, but I know now
@Alche_mist
@Alche_mist 2 жыл бұрын
@@analogfeelingshateswin32 Which still means that "the guys who wrote Unity" most probably did more C++ than C#. After all, game engine cores are rather huge and complex projects.
@TheFinagle
@TheFinagle 2 жыл бұрын
The answer to what is the fastest language always starts with "For what task?" for me. Some are optimized for high order math, some are efficient at memory management for large data manipulation, others are built with other kinds of tasks in mind. I have yet to hear of any one language that is perfectly optimized for all possible operations or tasks.
@NymezWoW
@NymezWoW 2 жыл бұрын
Good luck finding any scenario or task where for example Python outperforms C. Some languages simply are faster than others.
@nicolaslandau4692
@nicolaslandau4692 2 жыл бұрын
@@NymezWoW Python is faster at being written if that counts.
@tenhovergonha8739
@tenhovergonha8739 Жыл бұрын
@@NymezWoW I use JavaScript because it's fastest to me to program in any computer that have at least a browser and a notepad... (No need for internet to download anything more)
@nosuchthing8
@nosuchthing8 Жыл бұрын
@@nicolaslandau4692 no
@stilles342
@stilles342 2 жыл бұрын
Thank you Dave for reuploading the video. This one works properly in 1080p!
@hypersonic12
@hypersonic12 2 жыл бұрын
Ok I’m hooked and looking forward to the next episode! Great concept
@ryan-heath
@ryan-heath 2 жыл бұрын
Isn't the best compiler the winner, and not necessarily the language it compiled?
@whatevah666
@whatevah666 2 жыл бұрын
That would be a huge part of it, yes :)
@paulburger9904
@paulburger9904 2 жыл бұрын
Jip, it's all about which compiler produced the best machine code.
@kaseyboles30
@kaseyboles30 2 жыл бұрын
To a large degree yes. However it's possible some constructs in some languages are very hard to translate to efficient machine code. And of course as time goes on and effort is applied the compiler for a language will tend to get better. That said there can be a trade off between speed and size. Also not all languages are compiled.
@klaxoncow
@klaxoncow 2 жыл бұрын
Indeed. And if the programmer was good enough - and time was no object - then assembly language would be intrinsically impossible to beat. Because every other language is being translated into machine code, and assembly language is just human-readable machine code. So, you know, anything a compiler could potentially do could, at least in theory, be simply manually duplicated in assembly language. "Anything you can do, I can do better. Anything you can do, I can do as well". Of course, in practice - which is why I stipulated that "time was no object" - reaching, and then exceeding, all possible compiler output would not be quick and it would not be easy. But it is always, by definition, possible. So, like, no-one ever really uses assembly language, other than for small performance-critical routines, as it's too slow and impractical for the majority of programming. (And, indeed, with assembly language, there's a fundamental "cheat" available that no other language can do - first, use your compiler and obtain its assembly output, then go through it and make improvements. So, again, assembly language, by definition, is intrinsically impossible to beat. As you can actually USE the other languages to produce assembly output and then manually tweak it to be just that slightly bit better. The reverse ain't possible.)
@kaseyboles30
@kaseyboles30 2 жыл бұрын
@@klaxoncow A couple decades ago I would have completely agreed with you. However with modern cpu's so much is going on that it's unlikely a human could out-optimize a good compiler. Now with out of order executions, multiple layers of cache, hyperthreading, etc. there are just to many variables for one person to track and account for in any non-trivial program. You do not however want to abstract away programming itself. I'm not sure how to express what I mean, but one of the many weaknesses I see in some modern languages and coders is lack of awareness the intrinsic differences between human reasoning and computer operation.
@tekman82
@tekman82 2 жыл бұрын
Well, well... this project will be a rosetta stone in the future.
@boluaygepong5920
@boluaygepong5920 2 жыл бұрын
Facts‼️😭
@meylaul5007
@meylaul5007 2 жыл бұрын
I must say, seeing the Github for this is an absolute joy! So many different approaches to implementations all with the same purpose and very funny by the way. Is there actually an attempt by someone to implement it in a esoteric language, or don't we do that here? Shakespeare by any chance? :D
@nonobrochacho240
@nonobrochacho240 9 ай бұрын
I thoroughly love this channel and am grateful you’re doing it.
@phi1111ip
@phi1111ip 2 жыл бұрын
An excellent idea for a series, the execution is fantastic as well.
@garrykraemer8993
@garrykraemer8993 2 жыл бұрын
I can't wait to see more comparisons! AWESOME sound effects during 'execution'! I was a real-time SW engineer on the B-52G/H flight simulator (6 DOF) and F-15 C Flight simulator, F-15 E Weapon System trainer, plus F-15S Aircraft Maintenance Trainer. Languages: Fortran IV/7/95, C, ADA (F-15 Central Computer - 486), JOVIAL (B-52 Avionics), C++, C#, and big symbol dictionaries! A 'cold start' would take days! Over a million lines of code. The B-52 also had very large radar and visual database sets! That was over 30 years ago.
@dale116dot7
@dale116dot7 2 жыл бұрын
I do automotive engine management and reboot time is one metric I’m always trying to improve, I look for a reboot and resynchronization on a running engine within 200ms. Probably a quarter million lines in C and just a tiny bit of assembly. It’s interesting to hear all of the different programmers and engineers on here.
@choasisgoated
@choasisgoated Жыл бұрын
Yoooo have you have you heard of dcs? I bet some company who makes software for dcs would love to talk to you. Your a legend man.
@thewaver8
@thewaver8 2 жыл бұрын
IIRC with Delphi, you have "Int64" or you can use an unsigned version of Integer, AKA "LongWord". Also, you can check directly whether a variable is nil. "Assigned" is just a "convenient" way to not have to worry whether that variable holds a function pointer (@myVar nil), or a value (myVar nil).
@pauldhartley
@pauldhartley 2 жыл бұрын
I attended a meeting of the Forth Interest Group in Palo Alto in the 1970s, one group of Forth programmers explained they had worked on the project to send a rover to Mars. They were supposed to use ADA to program the rover but unbeknown to the 'suits' used Forth. They claimed that the arm on the rover holding the camera was damaged on take-off and because Forth had been used to control the camera could re-program the code to make the rover move instead of the camera arm when panning the camera while the rocked was on its way to Mars. It certainly was a very interesting group of people, a meeting I remember with great interest ever since.
@abc.2924
@abc.2924 2 жыл бұрын
Amazing
@DavesGarage
@DavesGarage 2 жыл бұрын
We need a FORTH impl, actually!
@PR-fk5yb
@PR-fk5yb 2 жыл бұрын
The most interesting and valuable thing is that FORTH can be implemented on absolutely anything that has a stack and can manipulate it with PUSH, POP and ROT values. I have used it extensively to port different cpus implementations across different test jigs (in ancient times). Unfortunately, I doubt it could win such a sieve race because it is so stack intensive and burns memory like hell. On the other hand it is a langage that does not do any floating point arithmetic (yes no need for that) and is best suited for integer calculations. So for findings primes, it will have a edge there. Really looking forward to the results.
@vspecky6681
@vspecky6681 2 жыл бұрын
This is amazing content. Can't wait for more!
@tech5882
@tech5882 2 жыл бұрын
Delphi and it's open source alternatives (Lazarus etc) are still VERY popular among independent Windows tools devs.
@fonkbadonk5370
@fonkbadonk5370 10 ай бұрын
Glad to see this comment in the wild. Pascal and its derivatives get a lot of pity these days, but I've sustained a good living for the last >25 years by writing indvidual one-off tools for specific customers using Delphi. It has been able to generate mobile apps for years as well. It's a modern language with a (still mostly) healthy ecosystem. The one complaint I have is, that its documentation has been taking a steep dive during the last couple of years, making it nearly necessary to get a version with full sources to properly learn what lib function behaves how. I'd say it suffers a LOT more due to its undeserved reputation, instead of its actual merits.
@VoxyGon
@VoxyGon 2 жыл бұрын
Sweet series! I've got to assume the Pascal working with 32 bit values is giving it the speed advantage over Ada working with 64 bit values (especially since performance is pretty close to 2x). Really interested to see how things evolve at the end of the series!
@lordcheezus1
@lordcheezus1 2 жыл бұрын
Just discovered this channel, and Dave - You are awesome! Your very well spoken and entertaining while providing very detailed information in a pleasing way. I love watching your videos and aspire to watch more!
@dolsimon
@dolsimon 2 жыл бұрын
This is so interesting :D Great project man!
@DavesGarage
@DavesGarage 2 жыл бұрын
Thanks a lot! It'll get more interesting as I can dispense with all the talk up front and spend more time with the code!
@fburton8
@fburton8 2 жыл бұрын
It will be interesting to see how much the benchmark results are improved by contributors. This is a fascinating project.
@ShALLaX
@ShALLaX 2 жыл бұрын
Fantastic! Just what I hoped would happen with all these implementations!
@travails3829
@travails3829 2 жыл бұрын
Delphi has an optimizing compiler that was always ahead of its time. Would have been nice to see the results.
@rgoodwinau
@rgoodwinau 2 жыл бұрын
First language at uni was Pascal. Went on to retarget the Modula-2 compiler (also a Wirth language) to cross compile to the Intel 8086 for my honours year. Later, working at the uni as a DEC-10 sysprog (back in the days when we had source code for the OS), I discovered and fixed a code generation bug in the Pascal compiler. Pascal (with extensions) was a very capable language if you knew what you were doing, even for system programming tasks!
@mollybell5779
@mollybell5779 2 жыл бұрын
Great stuff. Thank you, Dave. 😁
@rodhester
@rodhester 2 жыл бұрын
Very well put together video. Thank you
@shizeeque
@shizeeque 2 жыл бұрын
the moment I saw Rust and Zig on the screen I said to myself: It's a legit channel on my KZbin Subscription list. 👌 Great Job, Dave!
@markusmaeder1388
@markusmaeder1388 2 жыл бұрын
What a cool video. Back in the days, I benchmarked every language I could get on my computer. Today performance is more about choosing the right architecture and implement features as fast as possible. If it is too slow, throw more hardware (virtual) at it. The art of tuning performance is neglected and underestimated today. Many programmers tend to not understand all the complexity involved executing their highly abstracted code using thousands of libs. If code doesn't work, pray they find the problem. :)
@portlyoldman
@portlyoldman 2 жыл бұрын
I distinctly recall rewriting batch programs so that they could run overnight in the period between when everyone went home at night then returned in the morning. Delivering the printouts to their desks by 9am.
@davidfirth1
@davidfirth1 2 жыл бұрын
My first job out of college was as a software engineer for.a small company that did embedded systems in Forth and the host software in Turbo Pascal. I actually fondly remember TP 5.5 and 6.x. Extra points if someone still has TP 3.0, which was the first real compiler that I owned. Prior to that, I was punching in hex codes or messing around a little with Z80 assembler.
@hatcherluke
@hatcherluke 2 жыл бұрын
Another interesting comparison for languages like Python would be using different implementations. For Python, CPython (the standard implementation) vs. pypy (a fast but compatible implementation using a JIT compiler). Edit: Looks like this already exists in the community branch. Great!
@WasiMaster
@WasiMaster 2 жыл бұрын
Jpython, ironpython, brython etc.
@hercion
@hercion 2 жыл бұрын
did you check out NUMBA? with numba, you can jit-compile individual python functions by marking them with @jit and get amazing performance. in the background llvm will do the machine code generation.
@semuta2752
@semuta2752 2 жыл бұрын
@@hercion I’m looking at the documentation now and holy hell that’s such a neat and useful tool. I appreciate you sharing NUMBA’s existence here! Cheers
@di380
@di380 2 жыл бұрын
I would also like to point out that results might vary greatly depending on the compiler. Even with C++ you can see performance differences between different compilers on the same exact code implementation.
@GregMoress
@GregMoress 2 жыл бұрын
Exactly. The language makes no difference, other than making conveniences available, such as object-orientation.
@falklumo
@falklumo 2 жыл бұрын
@@GregMoress Yes, but some languages are more susceptible to compiler optimizations than others. E.g., Fortran which can beat assembly written by mere mortals.
@Tom55data
@Tom55data 2 жыл бұрын
@@GregMoress Yes it does, some languages have primitives and some do not, which is very significant for computation - some languages have better implementation of high precision numbers, some languages have better implementations of string (multiple-byte representations of languages) and so on. In real cases we have to deal with large data flows (genomics), rapid calculation (interactive 3D manipulation for example), or just calculations of high precision data (machine learning). Although the quality of compilers is important, the ability of a compiler to take logic implementations and create machine code that is efficient ends up at a limiting point based on the underlying structure of the language and its design to make it easy for a user and create code efficient for a chipset. For example; how can an interpretive language fully implement refactoring of code or code look-ahead when it is interpreting one line at a time.
@MrKentaroMotoPI
@MrKentaroMotoPI 2 жыл бұрын
Yep. I have Fortran coal reactor chemistry codes that are ~10K lines. The Intel compiler executables run ~ 8x faster than GNU (Gfortran) compiler executables. AVX optimizations on GNU yield nothing. On Intel, they yield about 30%.
@compuholic82
@compuholic82 2 жыл бұрын
Indeed. Compilers can make radical a difference and in some (usually rather simple cases) even change the complexity class of an algorithm. If you write a simple program that sums the numbers from 0 to N in a loop some compilers recognize that and replace the loop with a closed-form solution. So you have replaced an O(N) algorithm with an O(1) algorithm. So it is debatable whether a comparison between languages makes sense if the algorithm that is executed on the machine actually differs from the algorithm you wrote. Check out the KZbin video "What has my compiler done for me lately" if you like compiler magic.
@renancosta2644
@renancosta2644 2 жыл бұрын
That's quiet interesting, looking at the pascal source code we can check lot of things that could be optimized, including the choice of the map, pascal has lots of dictionaries with different goals.
@Axel_Andersen
@Axel_Andersen 2 жыл бұрын
The video was TLDR and boring for me so I did not watch it all. But from your comment I gather some libraries were involved. In that case all bets are off. A system library is hopefully highly optimised, but has severe constrains to comply with what ever spec it has. An other library maybe targeting a different spec and might utilise for example GPU. Unless the libraries are coded in the host language (as opposed to for example assembly) then this is really not about comparing languages.
@willboler830
@willboler830 2 жыл бұрын
It's cool to watch you get better at YT over time
@HeavyD6600
@HeavyD6600 2 жыл бұрын
Excellent video, Dave! Thanks!
@DavesGarage
@DavesGarage 2 жыл бұрын
Glad you liked it!
@juanma9511
@juanma9511 2 жыл бұрын
Great stuff dave !!
@Ensue85A
@Ensue85A 2 жыл бұрын
In secondary, I studied Apple II c/e line interpreted BASIC, at DeVry Insitute I then studied i8085A binary HEX, and machine code, followed by ANSI C.
@29Aios
@29Aios 2 жыл бұрын
I think OpCodes of different processors should be included too. However ASM is good, but probably it can be optimized with OpCodes, not sure, but hope
@warrendemars
@warrendemars 2 жыл бұрын
Love the outtakes!
@sanchezramirez4280
@sanchezramirez4280 2 жыл бұрын
Huge knowledge, and experience. I am amazed. Due to your influence, I will back to c++ which I lerned in 1999-2003 and start lerning another language. C#, Kotlin/Java or Python I think. It becomes very interestic for me. Maybe I will change my job as computer graphic artist to programming/coding.
@johnterpack3940
@johnterpack3940 2 жыл бұрын
This is awesome. Entertaining, educational, pure greatness. But I do have to agree with the other commenter who questioned whether it's truly indicative of a language's relative performance. At the extreme, Powershell and Bash are completely out of their element here. So if one trounces the other will that really tell us anything? That said, I'm at a loss to come up with a better test. And I'm still eager to see all the results.
@theharbingerofconflation
@theharbingerofconflation 2 жыл бұрын
Can't wait to see a comparison between Swift and C/C++
@LonersGuide
@LonersGuide 2 жыл бұрын
Delphi's Object Pascal (when it was a compiled to language) was comparable to in performance to C++. In the case of memory-management-intensive applications, it was a lot faster than Visual C++.
@zobook
@zobook Жыл бұрын
I use Lazarus at work and is great and fast
@fonkbadonk5370
@fonkbadonk5370 10 ай бұрын
Delphi / Pascal has such a MUCH worse reputation than it deserves. Fostered mostly by people that only had contact with it during th 90s and early 2000s, and aren't aware that Delphi today is a fully featured, mobile-capable IDE, and can produce very modern and quick executables. On windows espsecially, its ability to remove a LOT of dependencies and result in a monolithic executable makes for a really sleek deployment process. Yes, the executables are 20MB+ even for an empty window. But you also don't have to install literal gigabytes of libraries to be able to simply launch it, and you also don't have to micro-manage their version composition on top. It's just sad that Delphi's current owner is simply terrible at marketing IDEs, and documentation has been neglected a lot in recent years. The IDE and compilers are great though, and up to speed.
@nickryan3417
@nickryan3417 2 жыл бұрын
Yep, can certainly see some optimisations for Pascal, Object/Delphi Pascal but even for ADA (although I am definitely not familiar with it enough to really do it justice). My prediction for the fastest will be assembly, but that would require an experienced assembly coder and those are much rarer than other languages. The optimisations that modern compilers, and even the Intel vs generic compilers produce are incredibly sophisticated and this is why it would require an experienced assembly coder to beat them.
@vitor000000
@vitor000000 2 жыл бұрын
Amazing video!
@smidi4711
@smidi4711 2 жыл бұрын
Great video 👌
@robsku1
@robsku1 11 ай бұрын
Man, that Turbo Pascal screenshot brings back strong memories from my early years at programming =)
@zehph
@zehph 2 жыл бұрын
48 seconds in and holy crap balls, had to pause and say that the video quality got turned up to eleven! Good stuff!
@lepidoptera9337
@lepidoptera9337 2 жыл бұрын
The fastest computer language in the world is the correct algorithm for the problem.
@unclerojelio6320
@unclerojelio6320 2 жыл бұрын
The first couple of semesters of CS at The University of Texas back in the 80’s used Pascal culminating in a compiler class where used C to write a Pascal compiler. Good times.
@theovandaele3220
@theovandaele3220 2 жыл бұрын
If I'm not mistaken the Delphi compiler was written in C, but the IDE was written in itself.
@RamLaska
@RamLaska 2 жыл бұрын
Did you have Nell Dale's class?
@unclerojelio6320
@unclerojelio6320 2 жыл бұрын
@@RamLaska No, but we used her books. Still have them as a matter of fact.
@omnicoinv2
@omnicoinv2 2 жыл бұрын
@@unclerojelio6320 Id like to inform you that writing a pascal compiler in C is still the basis of the compilers course at UT in 2021. Hook em
@RamLaska
@RamLaska 2 жыл бұрын
​@@unclerojelio6320 Neat! My mom had her class in the early 80. So early that her textbook (which was used for a couple decades or so) was literally just printed out and bound in a HUUUGE 3-ring binder. I think I might still have the binder somewhere, but I removed most of the pages to save space.
@JuanManuelCuchilloRodriguez
@JuanManuelCuchilloRodriguez 2 жыл бұрын
In my university, they are still using Pascal to introduce students to programming. Obviously, Ada is a mandatory language for the "Programming languages" course. I loved this episode!
@Grantherum
@Grantherum 2 жыл бұрын
Pascal is really nice to teach newcomers to programming, as it kind of instills some "best practices" inherently in programming. If you start in something like C, C++... that you can be lazy with the indentions, it takes longer to teach that out of someone, than to just teach it in the first place.
@Mark.Brindle
@Mark.Brindle 2 жыл бұрын
Pascal is a great and Borland added extensions that became almost standard. I have used UCSD Pascal, Olivetti, Fujitsu, VAX, Turbo Pascal V1.0, 2.0, 3.0 and all Delphi's up to Borlands demise. It has some fantastic features (such as sets) that make reading much easier. The book Data Structures Plus Algorithems = Programs is an awesome book by the author of Pascal.
@JuanManuelCuchilloRodriguez
@JuanManuelCuchilloRodriguez 2 жыл бұрын
@@Grantherum I actually discussed much about this topic, and as today I think is the best language to teach programming. It is typed, is readable, allows to pass parameter by copy or as reference, and allows pointers and manually managed memory. I know, memory managed language like C# or Java are less error prone and allows faster development, but I think it is easier going from Pascal to C# than going from C# to Pascal. If you know how to do something the hard-way, the easy way is trivial.
@Sauvenil
@Sauvenil 2 жыл бұрын
Nice, we had Turbo Pascal as an "intro" class as well, in 1996, but didn't have Ada. They offered FORTRAN as well but I didn't really see the point of it except as kind of a history lesson.
@Sauvenil
@Sauvenil 2 жыл бұрын
@@JuanManuelCuchilloRodriguez it's also compiled, so there's the opportunity to learn about the compiler chain too... things you don't learn with the scripted languages of web development.
@scottmilano2940
@scottmilano2940 2 жыл бұрын
The bit manipulation seemed the easiest place to make improvements. A list of bools or even a list of ints seemed to be a lot simpler to check/set than a bit. Memory limitation for bools to 1 million aren’t even close to an issue. Edit: Maybe I'm missing the point and the goal is a common algorithm that can be compared across multiple languages. It's just unusual to see space optimizations in code where storage limitations aren't an issue. I've optimized bits of code now and again, and trading memory for speed is usually the easiest way to optimize, that and -O2.
@somethingsomthing2456
@somethingsomthing2456 2 жыл бұрын
unless your working in a low memory system (microcontrollers) then bit set and check manipulation becomes near necessary, but yhea (list/array of bools / ints ) for modern computers it should be pretty quick since it could do the whole computation in a single ALU call
@fvbakel
@fvbakel 2 жыл бұрын
It matters because a small bit array can fit in the L2 cache of the CPU.
@scottmilano2940
@scottmilano2940 2 жыл бұрын
@@fvbakel Take a look at the code, cache has little to do with the optimization. I thought he needed to get, or-in, and then set each value. But that's not the case. He's or-ing in 64 values at a time. Basically he takes a prime, 2 for example, creates a 64 bit value 0b10101010 ... and then just or's it in 64 bits at a time.
@MsDuketown
@MsDuketown 5 ай бұрын
I learned programming in Pascal and still love it. The native 32-bit sieve supports packed arrays and allows integer operations, including negative index and lookups in the dict. Other interpreters typically in Office PC's are VBA, so testing that would make sense as well. And Rust would inject this office workstation with doping since Rust has great industrial support, similar to how Python has academic support, whereas PHP and Javascript are web languages. Currently I'm researching about testing and I don't use JAVA. With Super Tux and Minecraft Redstone I think I'm going to reorganise some unit tests.. Btw. Results may differ per compilers. And RAD development together with Microsoft SureStep can maintain the whole environment. Great video❤
@fburton8
@fburton8 2 жыл бұрын
I still use Delphi 7 for work and it's plenty fast enough for the programming I do - real time data acquisition, instrument control, signal processing, graphics and UIs, so I was a bit shocked at how slow Delphi was. Maybe Embarcadero would like to have a go improving the Delphi code... or their compiler! Maybe I should have a go (at the former), although I don't see huge scope for improving the existing code.
@valinhorn42
@valinhorn42 2 жыл бұрын
I've been using Delphi XE5 and later 10.4 professionally for the past few years in similar environments. I really like the commodities that Pascal-derived languages bring to the table compared to C. Sure it's a little slower than the latter, but it more than makes up for it in readability. The WYSIWYG GUI editor is also very neat.
@kimbomadsen
@kimbomadsen 2 жыл бұрын
@@valinhorn42 I uploaded an update to Git which doubles the performance (at least on my 1950x) using same algorithm, just optimized.
@TheSchwartzIsWithYouToday
@TheSchwartzIsWithYouToday 2 жыл бұрын
He did NOT show the Delphi results here, only what I think was FreePascal. Note that there are three Pascalish compilers on the market: Delphi, FreePascal, and Lazarus -- the latter two of which are FOSS. There's a Community Edition of Delphi that's free, so I'm not sure why it can't be used for this (unless it's due to some silly clause in the license that says you cannot publish benchmark results using it). All three support slightly different versions of Pascal, but it's a pretty safe bet you can compile a Delphi 7 app in the other two. Delphi 10.4.2 ... not likely.
@fburton8
@fburton8 2 жыл бұрын
@@kimbomadsen Well done, sir!
@valinhorn42
@valinhorn42 2 жыл бұрын
​@@TheSchwartzIsWithYouToday Fair point. I didn't mean to say that either Delphi or Pascal is slow, just that from experience, the compiler results for the most part aren't as performant as those you get from C compiled with GCC. My main point was that I like using Pascal (the language family) and that the GUI tools which Lazarus and Delphi offer are convenient. As for the Delphi licencing, the Community Edition permits the free distribution of programs up to an annual revenue of USD 5k if I remember correctly.
@wilhelmsarasalo3546
@wilhelmsarasalo3546 2 жыл бұрын
Fpc/Lazarus here, I do C, C++, various assembly langues etc. Pascal makes you type more, but a typo is a syntax error instead something you did not intend. Similar end results.
@matthewv789
@matthewv789 2 жыл бұрын
Pascal was also the main programming language of the original Macintosh, including most of the OS and original applications like MacWrite and MacPaint. I’m not sure if other versions of Pascal support this, but Mac pascal supported pointers as well as “handles” - pointers to pointers - allowing the OS to move chunks of memory around without the application needing to know or care when it happened.
@thomasmeister8476
@thomasmeister8476 2 жыл бұрын
Borland's Turbo Pascal did support that as well - gave me the creeps when I was a kid, trying to learn to code
@alphabetaxenonzzzcat
@alphabetaxenonzzzcat 2 жыл бұрын
@@thomasmeister8476 Yeah, I remember using Borland Turbo Pascal for DOS back in the 1990s. It did support pointers - yes.
@davidmartensson273
@davidmartensson273 2 жыл бұрын
Turbo Pascal also supported virtual methods since the first object oriented version, 5.5.
@Herdatec
@Herdatec 2 жыл бұрын
15 Years ago I learned Pascal and Delphi in school. We were sad not to learn a useful language like C++. Well, now I've got a project to program in Ada. Life went full circle.
@dagbruck
@dagbruck 2 жыл бұрын
But note that Pascal wasn’t object-oriented in any way when it was designed. The comparison in the day was between C and Pascal. Modula-3 was the first OO derivative of Pascal.
@ArchaeanDragon
@ArchaeanDragon 2 жыл бұрын
The comparison of Pascal and Delphi versions is a bit confusing. Pascal (and ObjectPascal) has several dialects implemented in modern day compilers, and some compilers (like FreePascal) handle multiple dialects with compiler switches. Delphi is technically just a modern dialect of Pascal, specifically Object Pascal, with some minor function, keyword, and syntactic sugar differences, but is otherwise functionally equivalent as other Object Pascal dialects. I suppose it's fine for benchmarking its specific compiler optimizations and dialect, and seeing how it differs in performance, but the code isn't largely all that different between them. For example, Inc/Dec procedures exist in the original Turbo Pascal language spec, dating back to the early 80s and are (I believe) a staple of all modern Pascal dialects, not just Delphi. As such, I think the differences between the Object Pascal and Delphi versions showcased here are largely due to programmer preference.
@ultraderek
@ultraderek 2 жыл бұрын
You should do a in-depth side by side comparison video of each of the 45 languages.
@1992jamo
@1992jamo 10 ай бұрын
I'd at least love to see a chart with all 45 languages.
@edwardjaycocks5497
@edwardjaycocks5497 2 жыл бұрын
Great video Dave as always…….::) Retired network engineer giving you the thumbs up
@DavesGarage
@DavesGarage 2 жыл бұрын
Thanks for that!
@paco3447
@paco3447 2 жыл бұрын
Extremely well written and optimized assembly and C.
@jamescoulter9659
@jamescoulter9659 2 жыл бұрын
Depends. If it is permitted to allow compile-time computation of the result which is then simply stored in a static buffer (meaning the answer is stored in the executable), then languages that support this (e.g. C++) will be faster than any run-time calculation. Nothing is faster than a no-op. There is already an example of this in the repository by flo80 (under Primes/PrimeCPP/solution_3).
@davidconnelly
@davidconnelly 2 жыл бұрын
Shame we couldn't get Erlang on the list. Great video. Looking forward to the rest.
@JohnnyWednesday
@JohnnyWednesday 2 жыл бұрын
You have created an absolute storm in the Object Pascal world! Delphi coders and FPC coders are at war over your words ;)
@gorilladisco9108
@gorilladisco9108 2 жыл бұрын
I couldn't care less. I use FPC not because it's better, but because it's affordable. Delphi has gone from $40 during Turbo Pascal time, to $3,000 for current version .. I'm not going to mortgage my house to buy it, is what I'm saying.
@DavesGarage
@DavesGarage 2 жыл бұрын
Cool! I do hope their best and brightest head over to the repo to improve the algorithms before the finale!
@JohnnyWednesday
@JohnnyWednesday 2 жыл бұрын
@@DavesGarage - we're the OG strongly typed, object orientated language - Dart and Rust? are playing on our turf! we'll do you proud Dave!
@leosthrivwithautism
@leosthrivwithautism 2 жыл бұрын
Funny to see languages that I used back in high school days. Visual Basic and pascal are two languages I’ve used. Php, front pages, html, and Java are other languages I’ve used (except front page that was to build sites and not a language). Messing around with languages was when I noticed it wasn’t for me. I’m technical. Prefer to build and fix computers or programming them in what to do. That’s where I bow to this man for creating many tools I use today. Funny part about all this is that it’s been many years and when the code came up I was some what able to read it. So I did actually learn something back then.
@gregmurdoch3264
@gregmurdoch3264 2 жыл бұрын
I love this idea!
@OldePhart
@OldePhart 2 жыл бұрын
Bummer I thought this was live. Its better to see the outtakes in realtime :)
@SidneyCritic
@SidneyCritic 2 жыл бұрын
Can't we run 4 languages at a time like Charlotte - lol -, this is going to take ages.
@DavesGarage
@DavesGarage 2 жыл бұрын
Do they still have four wide drag races? I've not seen one in years!
@seanbrisson7928
@seanbrisson7928 2 жыл бұрын
0:25 1) Haskell , lua
@osgrov
@osgrov 2 жыл бұрын
This is really cool. As someone who only really uses C and assembly, it'll be a real treat to learn about all those languages. :)
@MagicNumberArg
@MagicNumberArg 2 жыл бұрын
Rust. If you do Assembly and C - the best Lang to look at next is Rust.
@Markus_included
@Markus_included 2 жыл бұрын
To be fair, most languages are pretty similar to C.
@abhinavchavali1443
@abhinavchavali1443 2 жыл бұрын
Have you looked into Rust? It's my favorite PL
@osgrov
@osgrov 2 жыл бұрын
@@MagicNumberArg not yet, but I've heard lots about it. Maybe now is the time. Will check it out, cheers. :)
@robsku1
@robsku1 Жыл бұрын
@@Markus_included If you want something that's different in very fundamental way, I'd suggest taking a look at Common Lisp - now I'm not a grandmaster of programming language knowledge, in fact I've yet to actually take learning more than very basics of Lisp programming, but I haven't seen anything else that's even close to being as different (disclaimer for asshats: I know I said Common Lisp, but I actually mean Lisp/Lisp-based languages in general, so nobody bring up other implementations than Common Lisp - like elisp or Scheme - to show that I'm wrong. Besides I'm not claiming there isn't anything as different from C). It's a damn interesting language as well - there is a joke about if God was a programmer they would use Lisp. There's another joke about God commenting on programming the universe where he says that he originally planned to do it with Lisp, but ended up hacking it all together with Perl. And despite my love for Perl, if the latter joke was true I feel it would certainly explain a lot ;)
@vogong
@vogong 2 жыл бұрын
Hi Dave , great work. Has Erlang been considered or has it already been suggested ?
@theovandaele3220
@theovandaele3220 2 жыл бұрын
Starting to watch this thinking I know the answer. I'll be honest after viewing it. Edit: OK, I'll have to wait a bit. My guess would be ASM. It may be interesting to note that Delphi supports inline Assembler. So you keep the pretty great OOP framework, but can go a level deeper when you really need the speed. I hope someone tries this (it's been too long for me). PS: did you ever meet Anders after you guys stole him (heheh)?
@johnny5805
@johnny5805 2 жыл бұрын
10 Print "Please make these videos more interesting for non-programmers"; 20 poke 23606,0 30 goto 10 All I know is Sinclair BASIC :-)
@johncochran8497
@johncochran8497 2 жыл бұрын
Try the following program... 10 A=1E18 20 B=1E19 30 C=1E20 40 PRINT A*C 50 PRINT B*B Obviously, the result should be two lines with the value 1E38. But I suspect you'll be surprised at what you actually get.
@MySonBand
@MySonBand 2 жыл бұрын
Hello from another Leatherlander ;) Interesting to see where this is heading.
@bertblankenstein3738
@bertblankenstein3738 2 жыл бұрын
Haha I thought the same thing. Good trying he didn't go there.
@mikeandersen8535
@mikeandersen8535 2 жыл бұрын
How much does the implementation of a language (compiler/interpreter) impact the results? Anyway, I find this is interesting from other aspects than just raw performance. :)
@FruchteisMitErdbeer
@FruchteisMitErdbeer 2 жыл бұрын
The implementation is literally the only thing that matters here. Anything else is just syntax. The best example is that LuaJIT can outperform C in certain situations. Normally, jit compiled languages are not quite as fast as compiled languages. But with the right implementation (LuaJIT is amazing), that can be outweighed
@mikeandersen8535
@mikeandersen8535 2 жыл бұрын
@@FruchteisMitErdbeer Remember one who once said that "languages are not fast nor slow, it is their implementation that is fast or slow". And I've seen many examples of that up through the years, from Microsofts and Intels Macro Assembler in the late 80s... to different JIT compilers for more "modern" languages. :) I hope Dave comments on this issue in the series he now makes. :)
@hansangb
@hansangb 2 жыл бұрын
@9:40 Borland compiler. Hello old friend!!!! Just being able to follow a variable and breakout to root out off-by-one errors changed my life! EDIT: LOLOLOLOL Just got to @17:47 Too funny, considering what I had typed a 17 min ago.
@j.f.christ8421
@j.f.christ8421 2 жыл бұрын
QuickBasic (v3?) could run your programs BACKWARDS! I did like how you could define bounds in Pascal, eg Month: integer 1-12;, and you'd get a runtime error if you tried to set it to 13 or something silly. Plus that let you do the PackedRecord thing to save space as well.
@johannhuman532
@johannhuman532 2 жыл бұрын
Thanks for talking about (Free)Pascal. Using the "packed" keyword does not put 8 booleans in one byte. For that you need to use "bitpacked" or some compiler directive. But then the compiler won't accept dynamic arrays. I've proposed an implementation using a pointer to bitpacked array. I've tested with actual bit-packed array, it was about the same speed for 1 million, but for 100 million, the bit-packed version was much faster, I guess due to reduced memory cache usage.
@JohnnyWednesday
@JohnnyWednesday 2 жыл бұрын
It's fine - you can enable / disable the bitpacking per unit (possibly round blocks of code too - I've not tried) - I do so for BSP visibility data and bit-plane functions on the Amiga using FPC while still allowing standard array access elsewhere
@johannhuman532
@johannhuman532 2 жыл бұрын
@@JohnnyWednesday I am not sure you got my point. bitpacked was not activated in the implementation and it was with a dynamic array.
@JohnnyWednesday
@JohnnyWednesday 2 жыл бұрын
@@johannhuman532 - oh my apologies - yes, I understand - we should ensure our language is fairly represented.
@johannhuman532
@johannhuman532 2 жыл бұрын
@@JohnnyWednesday no problem, you're forgiven. the keywords are similar
@markburhop
@markburhop 2 жыл бұрын
Just ruined my day off going though this and the earlier videos! Worth it.
@DavesGarage
@DavesGarage 2 жыл бұрын
Glad to hear it! Sorry not sorry! :-)
@guyincognito1985
@guyincognito1985 2 жыл бұрын
I come for the drag racing, but I stay for the outtakes.
@Forcoy
@Forcoy 2 жыл бұрын
Amazing!
@FarrellMcGovern
@FarrellMcGovern 2 жыл бұрын
I hope that someone implements this in Forth since I would like to see if the claims that Forth is like a "portable assembler" in terms of speed are true. I used to do some coding in Forth...but that was 40 years ago...and I have forgotten much about the language.
@PablumMcDump
@PablumMcDump 2 жыл бұрын
I believe that the only time I've seen Forth in the wild was in the Sun OpenBoot environment.
@FarrellMcGovern
@FarrellMcGovern 2 жыл бұрын
@@PablumMcDump I played around with that on the Sun boxes I have owned. I still have an Ultra 60 that someday I would boot up again. Postscript is a very close cousin to Forth. A bunch of instruments used in Aerospace and Aviation run on Forth. There are lots of embedded real-time control systems that used to run Forth...I don't know about today. I'm totally out of the programming field, doing mostly Unix/Linux sysadmin stuff.
@ce9916
@ce9916 2 жыл бұрын
It probably wouldn’t fare much better than forth position
@joepike1972
@joepike1972 2 жыл бұрын
@@FarrellMcGovern The XO-1 computers that were part of the give one get one program of the One Laptop per Child had Forth open firmware on them.
@FarrellMcGovern
@FarrellMcGovern 2 жыл бұрын
@@joepike1972 Nice! I didn't know that!
@shiorinyan
@shiorinyan 2 жыл бұрын
By the way found a typo in description, Haskell, not Haskel. (Btw good video)
@dmh20002
@dmh20002 2 жыл бұрын
Lol I learned Pascal in school in 1979 and used it in my first job starting in 1981. But this Pascal blew my mind. A lot if stuff that was not there back then.
@Luix
@Luix 2 жыл бұрын
hi, do you have the graphs of all implementations? I’d like to see cpp, rust and golang hand to hand.
@Ghandacity
@Ghandacity 2 жыл бұрын
I C you're very good with the Pascal puns. Do you have any pointers so I can reference them later?
@fllthdcrb
@fllthdcrb 2 жыл бұрын
18:41 I'm hardly familiar with Ada, but just looking at the code, it seems to me there are two different syntaxes for converting a number to a string being used here: varname'Image converts a variable, while type'Image(funcname) converts the return value of a function. At least I think that's how it works. It seems that simply referencing a nullary function calls it in Ada; maybe the latter syntax is just an alternate way that works for variables too. Also interesting that you apparently have to specify the type even though it's already declared on the function. One strange thing is Num'Img about halfway down there. Is "Img" an alias for "Image", or is there some other subtlety?
@bassbacke
@bassbacke 2 жыл бұрын
The outtakes were the final bits that made me push that like button. Great video, Dave!
@DavesGarage
@DavesGarage 2 жыл бұрын
Glad you enjoyed it!
@omfgbunder2008
@omfgbunder2008 2 жыл бұрын
This sounds like a series that could use a godbolt assembly comparison to see why any given language is faster than another. 👍
@sang3Eta
@sang3Eta 2 жыл бұрын
Delphi is to Pascal as Visual C++ is to C. Far easier to code and debug in Pascal it's a very underrated language. Much faster than Visual Basic at runtime.
@bsvenss2
@bsvenss2 2 жыл бұрын
I was involved in an Oberon project with Niklaus Wirth in 1992 when I studied Computer Science. Great guy. Also, Anders Hejlsberg's wife worked at the same company as me a couple of years ago. It's a small world.
@FIDELOROZCO
@FIDELOROZCO 2 жыл бұрын
Mr. Wirth and Hejlsberg works has been highly influential in the profesional lives of many programmers. High honor have been chance to interact with them.
@GbpsGbps-vn3jy
@GbpsGbps-vn3jy 2 жыл бұрын
It's usually a hand-written assembly or manually optimized the one generated by compiler. That's the first part, the second is for what architecture we're writing and what's the problem
@isuller
@isuller 2 жыл бұрын
Not sure. A manually optimized code would run fast on one architecture, but slow on other. Maybe a JIT style interpreter would be faster. I'm not sure - a "current status" would be nice to see though :-)
@GbpsGbps-vn3jy
@GbpsGbps-vn3jy 2 жыл бұрын
@@isuller Good comment, but try to read my second sentence.
@unsafecast3636
@unsafecast3636 2 жыл бұрын
About 32-bit integers - they're actually slower than 64-bit ones on a 64-bit machine! So it's not only the range, the performance is affected too
@ce9916
@ce9916 2 жыл бұрын
I wish you’d explain, this is so counterintuitive!
@nickcarter4006
@nickcarter4006 2 жыл бұрын
I’m not knowledgeable in any way about this but I assume it’s because the 32-bit integers have to be reinterpreted to 64-bit in an amd64 machine. Can someone confirm?
@unsafecast3636
@unsafecast3636 2 жыл бұрын
@@ce9916 I think I spoke early here. This depends A LOT on the architecture and use case. For example, if you're bottlenecked by memory bandwidth, just use smaller integers, any benefit you get from arithmetic speed will not matter at that point, just get as many integers through the bus as you can. If you're bottlenecked by the processing speed, that's a whole different story. I'm not very sure about x64, but I know some 64-bit architectures don't have 32-bit arithmetic especially - so they have to convert very often. Also registers, some can't read from fractional registers like x64 does (ax/eax/rax), so again, conversions everywhere. But sometimes it just doesn't matter. Benchmark it and see which is faster.
@ce9916
@ce9916 2 жыл бұрын
@@unsafecast3636 Thank you! I naively assumed that it would just treat 32b ints as 64b ints and ignored the extra space.
@brdrnda3805
@brdrnda3805 2 жыл бұрын
How about float vs. double? Can it have performance impact to use float on a 64-bit CPU?
@matt_b...
@matt_b... 2 жыл бұрын
The sunburn, the shirt... Welcome back from Hawaii?
@____-gy5mq
@____-gy5mq 2 жыл бұрын
Or Miami?
@mayank8387
@mayank8387 2 жыл бұрын
Or Vice City?
@JohnWasinger
@JohnWasinger 2 жыл бұрын
Adept V+ is a language used for industrial robotics. If provides a real-type response and it is an uncompiled script language.
@bertblankenstein3738
@bertblankenstein3738 2 жыл бұрын
I look forward to seeing the languages I've done some programming in like C, C++, and PERL. Perl impressed me with the text processing pattern matching capabilities. I hope it also does well with this task. Also of interest, powershell vs bash. I look forward to the next installment.
@maxwellsmart3156
@maxwellsmart3156 2 жыл бұрын
It really depends with Powershell if the point is performance. Do you use just cmdlets or include .Net. The first can be unbelievably slow while .Net can change it from unusable to giving extremely good performance.
@iddn
@iddn 2 жыл бұрын
Perl is dead
@RamLaska
@RamLaska 2 жыл бұрын
My problem with the bash implementation is that it runs a loop to find square roots instead of calling `bc` I guess that's true to "bash ONLY," but nobody in the real world would write a bash script like that. It's always about using the strengths of the system it's on.
@robsku1
@robsku1 Жыл бұрын
@@iddn No it isn't, it just smells funny. If you're a Linux user and feel that Perl is dead, do check if it's installed and if it is, uninstall it. Nevermind whatever gets uninstalled because they have it as dependency, why would you need such things? ;) Seriously though, dumb comments like that used to irk me when I was younger - but now I'm more interested in getting even one proper answer from someone to this question: Why did you feel the need to express that particular opinion in this particular place? I don't want to try "guiding" you to answer in certain way, but does it have anything to do with bertblankenstein3738 saying that he was impressed by something in Perl, did that trigger you somehow? I've yet to receive answers from others, and maybe it's a hard question, but maybe you'll be the first? - Your Friendly Neighbourhood Perl Hacker, Sir Robin Janegirl S.
@robsku1
@robsku1 Жыл бұрын
@@RamLaska I have no problem with that - the problem you're having is really about bash not being exactly ordinary candidate for this benchmark. What is being benchmarked here is the performance of the language itself - of course it's kinda silly to put bash in this place at all, because this benchmark is about the performance of the language itself in doing something bash is not designed for; it's a shell script language, you're not expected to use it to do this. The problem in something like giving bash a special permission to call other executables, how is that fair to other languages - are we going to let Python implementation use 3rd party high speed C/C++ libraries as well? Will we just ignore the whole thing about benchmarking performance of the language itself? I would accept if someone made an entry like bash+GNU coreutils - that would tell what executables can be called. You're idea of calling 'bc' has the problem that bc isn't installed by default on any distro I've used lately. Besides wouldn't it make more sense to write the whole thing in bc - I actually didn't see if it's possible, but I think it's lightly. If not, then maybe an entry for "bash+bc" would actually make sense. But you have to either define what your script depends on - you could also define entry "POSIX Shell Script" and write a shell script that has no other dependencies, meaning it's gotta work with what's available on any UNIX/Linux system (unless they've been stripped down). But that wouldn't be a bash script - and in fact I recommend using Heirloom Bourne Shell to test scripts that need to run on any POSIX environment they are thrown in; I discovered at least one thing bash does differently from Bourne Shell even in POSIX compatibility mode. If your using Linux or UNIX system which doesn't come with plain bourne shell, Heirloom Bourne Shell is quick and easy to download, compile and install ;) I wrote a version of 'tree' command that supports 'dircolors' (AKA LS_COLORS) that is sh-only ;) POINT: You have to take bash having even an entry on this less seriously - the only problem is that bash is not in the right place, and it's only here because hackers like fun things. And implementing this in pure bash is FUN, there's not a single reason besides it to do this. Think about it. Someone made a "standard" for creating bash programming libraries, like libraries in other languages. Someone else used it to write bash-library that makes it possible to do OO-programming in bash. I'm planning to create a fixed point math library for bash scripts - does any of that make sense to you? It's not supposed to, it's supposed to be fun, hacks for the sake of hacks! `\,,/_[>
@tommat86
@tommat86 2 жыл бұрын
I get between 1300-2400 with the pascal bench. Not sure why the numbers are that far apart, but they are much higher than 143. That's on an AMD 2700X
@oddolavssn8343
@oddolavssn8343 Жыл бұрын
After starting programming in Basic, some z80 and m68000 assembler, Pascal was the language that really taught me 'disciplined' programming. That is writing 'easy to understand' code, EVERYTHING must be pre declared, the difference between formal and actual parameters etc, etc. I just loved programming in Borlands Turbo Pascal. It's so sad it 'died'... It was not a great score Pascal got, b.t.w. 😞
@julkiewicz
@julkiewicz 2 жыл бұрын
I wish someone did benchmarks for how fast languages 1) compile 2) load their runtime
@MB199494
@MB199494 2 жыл бұрын
Oooh, maybe I should look at the Fortram implementation
E01: Stupid C++ Tricks with Dave
15:43
Dave's Garage
Рет қаралды 306 М.
Ages 1 - 100 Decide Who Wins $250,000
40:02
MrBeast
Рет қаралды 89 МЛН
Суд над Бишимбаевым. 24 апреля | ОНЛАЙН
7:26:50
ВИРУСНЫЕ ВИДЕО / Мусорка 😂
00:34
Светлый Voiceover
Рет қаралды 3,4 МЛН
РАДУЖНАЯ ГОРКА 🌈😱
00:30
ВИОЛА 🐰
Рет қаралды 3,4 МЛН
Docker vs VM:  What's the Difference, and Why You Care!
13:40
Dave's Garage
Рет қаралды 134 М.
The 10 Second Autism Test: What's YOUR Answer?
10:38
Dave's Garage
Рет қаралды 1 МЛН
Top 10 Most Useless Languages to Learn
7:56
Language Simp
Рет қаралды 1,7 МЛН
What Is an AI Anyway? | Mustafa Suleyman | TED
22:02
TED
Рет қаралды 296 М.
Blame Me: I Worked on the Windows Progress Dialog!
16:26
Dave's Garage
Рет қаралды 380 М.
The Race to Build the World’s Fastest Supercomputers | WSJ U.S. vs. China
6:36
The Wall Street Journal
Рет қаралды 201 М.
Scroll Lock - The Secret Key THEY Don't Want You to Press!
9:51
Dave's Garage
Рет қаралды 931 М.
Most Popular Programming Languages 1965 - 2022
6:47
Data Is Beautiful
Рет қаралды 1,4 МЛН
План хакера 🤯 #shorts #фильмы
0:59
BruuHub
Рет қаралды 818 М.
Why spend $10.000 on a flashlight when these are $200🗿
0:12
NIGHTOPERATOR
Рет қаралды 14 МЛН