First new post in 2 weeks!

This commit is contained in:
Anthony Wang 2020-09-16 21:45:53 -05:00
parent fa7b4cd2d7
commit fc0d02f2c4
Signed by: a
GPG key ID: 6FD3502572299774
2 changed files with 23 additions and 17 deletions

View file

@ -1,17 +0,0 @@
---
layout: post
title: "print(\"Hello, world!\") - Part 1"
date: 2020-09-01 11:55:04 -0500
author: Ta180m
tags: ["Programming"]
---
There are a few reasons why competitive programmers use C++: it has a decent standard library, several good reference sources, and lots of tutorials online. But these factors are not unique to C++;
<script src="https://emgithub.com/embed.js?target=https%3A%2F%2Fgithub.com%2FTa180m%2Fprint-Hello-World-%2Fblob%2Fmaster%2Ftest.cpp&style=hybrid&showBorder=on&showLineNumbers=on&showFileMeta=on"></script>

View file

@ -0,0 +1,23 @@
---
layout: post
title: "print(\"Hello, world!\") - Part 1"
date: 2020-09-16 21:38:03 -0500
author: Ta180m
tags: ["Programming"]
---
There are a few reasons why the vast majority of competitive programmers use C++: it has a decent standard library, several good reference sources, and lots of tutorials online. But these factors are not unique to C++; what matters is its speed. A few milliseconds could be the difference between and accepted solution and time limit exceeded. Anyways, here's the code, about two weeks late, written in the "conventional" C++ style, as opposed to the condensed, macro-abusing style of competitive programmers.
<script src="https://emgithub.com/embed.js?target=https%3A%2F%2Fgithub.com%2FTa180m%2Fprint-Hello-World-%2Fblob%2Fmaster%2Ftest.cpp&style=hybrid&showBorder=on&showLineNumbers=on&showFileMeta=on"></script>
| Factor | Rating | Description |
| --- | --- | --- |
| Speed | 3 | Very fast after compilation, nearly as fast as C, and faster than a lot of programming languages even counting compilation |
| Documentation | 3 | Not that I used any when writing this program, but there a lot of good resources out there, such as [cplusplus.com](www.cplusplus.com) |
| General | 3 | C++ has its flaws, but for some applications such as competitive programming, it's unbeatable |
Be on the lookout for Part 2, Python! No guarantees about the date, but it should show up in a few days, once I get some time.