Skip to content

Instantly share code, notes, and snippets.

View senapk's full-sized avatar

David Sena Oliveira senapk

  • UFC
  • Fortaleza - CE
View GitHub Profile
@senapk
senapk / code_style.md
Created March 3, 2021 18:40 — forked from jesseschalken/code_style.md
Code style

My preferred code style is 2-space K&R. This is intended to provide a justification for this style.

Why K&R?

K&R style has the following properties:

  1. Provides symmetric size (in terms of screen space consumed) between the opening and closing syntax of a clode block.
  2. Forces no empty or meaningless lines, thereby avoiding artificial distance between related things that should be together.
  3. Consumes the minimum vertical space while keeping the opening and closing syntax of a block on separate lines from the content.
@senapk
senapk / arvore_de_decisao.cpp
Last active December 1, 2017 14:42 — forked from anonymous/arvore_de_decisao.cpp
Arvore de decisão gráfica
#include <iostream>
#include <vector>
using namespace std;
namespace aluno{
struct DcNode{
string key; //resposta
string value;//pergunta ou afirmacao