Skip to content

Instantly share code, notes, and snippets.

View FlashBarryAllen's full-sized avatar
🍇

吨吨 FlashBarryAllen

🍇
View GitHub Profile
@wolfiestyle
wolfiestyle / 01_animals.cpp
Created August 10, 2016 04:42
the classic Animal class example in C++ and Rust
// the OOP version in C++
#include <iostream>
// base abstract class. that is what we use as the interface
class Animal
{
public:
Animal(char const* name): m_name(name) {}
// this is required to properly delete virtual classes