C development on Linux – Comparison between C and other programming languages – II.

Introduction

Since in our first part of this article we said we expected you, the reader, to have some programming knowledge, in this part we want to help you get a on where C stands in comparison to other programming languages you might know. The choice of those languages was pretty tough because of various criteria, but in the end we stopped at C++, Perl and Python. Since programming languages can be classified in lots of ways (depending on paradigm, syntax or style, for example), we didn’t try to find languages that are in the same category as C. Instead, since the aforementioned languages are pretty popular in the Linux world, we chose them, mentioning what every language’s place is in the great scheme, what it’s generally used for and of course, the differences between them and C. This article will be structured as follows: we’ll start with important elements of every language, like variable declaration, typing or structure and compare that with how it’s done with C. Thusly we hope to give you an idea about the language before we start. The parts this article is made of will be exactly like the announced structure of this article, to make comprehension easier.

The comparison

Types, operators, variables

C++

C++ was initially named “C with classes”, which says a lot about its’ relation with C. It is widely seen as a superset of C ( thus C++ the unary increment operator ++ ) , introducing object-oriented programming features. Types are essentially used the same, with bool being introduced in C++ for boolean operations. Basically, when talking about C and C++ differences, most of those come from the OOP concepts C++ has and C does not. For example C++ has operator overloading, an OOP-specific term, which means that an operator may have different implementations depending on the data it’s operating on. For example, in C++ you can do this:

 
a << 2

Now, if a is an integer, this will do a bitwise operation on it (left shift by 2), but if a is an output stream, the above line will try to write a ‘2’ to it. This kind of behavior is one of the reason C++ is criticized for allowing poor programming practices. Variables and constants are declared the same way as in C.

Read more

Testing Internet connection speed from a Linux command line using speedtest-cli command

How to run a speed test from command line using speedtest-cli

Running a speed test can be very useful to verify the current state of an internet connection, for example, to verify that our ISP (Internet Service Provider) is respecting the parameters we are paying for, or to diagnose possible problems.

One of the most common ways to check ping, download and upload values is to run a test from the speedtest.net website. The speedtest-cli program let us run the same test from our beloved command line interface.

In this tutorial you will learn:

  • How to install and use the speedtest-cli application
  • What are the most useful options we can use to modify its behavior
Testing Internet connection speed from a Linux command line using speedtest-cli command

Testing Internet connection speed from a Linux command line using speedtest-cli command

Read more

GSConnect Controls in Tray

How To Use GSConnect For Android Integration in GNOME

KDEConnect has become the standard for interaction between Linux PCs and Android devices. IT can handle most tasks and does so very well.

For GNOME users, this usually means installing a ton of KDE dependencies on their system. It’s clunky, and it doesn’t integrate well with their desktop of choice. GSConnect is a GNOME client for the KDEConnect app that allows you to access all of the same functionality without loading up on KDE components.

In this tutorial you will learn:

  • How to Install KDEConnect on Android
  • How to Add GNOME Shell Integration To Firefox
  • How to Install GSConnect
  • How to Connect Your Phone to GSConnect

Read more

Best Terminal Color Schemes

The Best Linux Terminal Color Schemes For 2019

Terminal customization has become a fairly big hobby for Linux users. There are plenty of ways to spice up the Linux terminal and make it look modern and visually appealing. It’s not just for appearances either. A well thought out color scheme can help reduce eye strain and make working in the terminal a much more enjoyable experience.

The Top Terminal Color Schemes for 2019:

  • Gruvbox
  • Solarized
  • Dracula
  • Base16
  • Badwolf
  • Apprentice
  • PaperColor

Read more

Install BlackArch on Arch

How To Add The BlackArch Pentesting Repository To Arch Linux

BlackArch is a penetration testing distribution, similar to Kali Linux, but it’s built on top of Arch Linux. In reality, BlackArch is really a pre-configured Arch installation with an extra repository full of security tools. As a result, you can add the BlackArch repository to a regular install of Arch and gain access to all the same tools.

In this tutorial you will learn:

  • How to Download the BackArch Setup Script
  • How to Verify The BlackArch Script
  • How to Run The BlackArch Setup Script
  • How to Install a Package from BlackArch
  • How to Install an Entire Category from BlackArch

Read more

Install RetroArch

How To Install and Use RetroArch on Linux

RetroArch is a popular collection of the best free emulators for the PC. It opens up a world of thousands of classic games across multiple consoles. Unlike more “hackish” emulation solutions, RetroArch is made for mainstream use, meaning it features a complete and polished interface that just about anyone can use to play their favorite games.

In this tutorial you will learn:

  • How to Install RetroArch on Ubuntu
  • How to Install RetroArch on Debian
  • How to Install RetroArch on Arch Linux
  • How to Install RetroArch with Flatpak
  • How to Navigate RetroArch
  • Play A Game With RetroArch

Read more

Checking a website's SSL certificate with openssl.

How to install ssl on RHEL 8 / CentOS 8

As interconnected computer networks enter more and more fields of everyday life, cybersecurity is getting louder and louder. We protect our websites, the traffic on our websites, the computers we initiate the traffic from, maybe (part of) the disks our operating system run from, our connection to work, the computers we attach to at work, and so on.

openssl is an essential tool on any recent GNU/Linux distribution if one have to work with various certificates.

In this tutorial we will install (and reinstall) the openssl package, and test it’s functionality by checking a website’s certificate chain with it’s help.

In this tutorial you will learn:

  • How to install openssl
  • How to reinstall openssl
  • How to check a website’s SSL certificate chain with openssl

Read more

Configure Monitors With Xrandr

How To Configure Your Monitors With Xrandr in Linux

Just about every desktop environment comes with some way to configure and control your monitors, but some aren’t quite up to par, and bugs can be a factor. Then, there are tiling window managers and more minimal desktops that don’t have those utilities. In any of these cases, Xrandr, the Xorg’s own utility for monitor management is your best friend, and it’s not too hard to use.

In this tutorial you will learn:

  • How to Find Info About Your Monitors
  • How to Set Your Monitor Resolution
  • How to Set Your Monitor Refresh Rate
  • How to Manage Dual Monitor Setups

Read more

Pandoc File Format Map

How To Convert Document Filetypes With Pandoc in Linux

File formats can be a pain to work with, and you definitely don’t want to copy and paste documents between programs. Pandoc is a powerful tool that allows you to convert your text documents between a huge range of formats on the fly. With Pandoc, you can write it once, and convert it for every platform and program you can think of.

In this tutorial you will learn:

  • How to Install Pandoc
  • How to Use Pandoc in Live Mode
  • How to Convert Documents
  • How to Use More Concise Flags

Read more

Budgie Desktop on Debian

How To Install the Budgie Desktop on Debian

Budgie is the popular desktop environment of the Solus OS distribution. It’s quickly gained in popularity and spread around the Linux world. Debian is no exception. Follow these simple steps to install this popular GNOME variant on Debian.

In this tutorial you will learn:

  • How to Install Budgie on Debian.
  • How to Start Up Budgie on Debian.

Read more

Pantheon Desktop on Debian

How to Install the Pantheon Desktop on Debian

Pantheon is one of the most popular new desktop environments in the Linux world. It was originally created for Elementary OS, but it’s spreading to other distributions. Unfortunately, there are no official packages for Debian. Learn how to install Panthon from a third party repository on Debian.

In this tutorial you will learn:

  • How to Install the Required Dependencies.
  • How to Download and Install The Repository.
  • How to Install Pantheon on Debian.
  • How to Install Pantheon Extras on Debian.

Read more