Skip to content

Instantly share code, notes, and snippets.

View xfbs's full-sized avatar
👋

Patrick Elsen xfbs

👋
View GitHub Profile
@xfbs
xfbs / soldier.cpp
Created August 23, 2011 19:28
Daniel's C++ Army Game
#include <iostream>
//#include <cctype>
#include <string>
using std::cout;
using std::cin;
using std::string;
using std::endl;
class Soldier;
@xfbs
xfbs / .gitignore
Created August 26, 2011 07:11
HTML Grundkenntnisse
.DS_Store
@xfbs
xfbs / drainbamage.markdown
Created August 27, 2011 15:35
Things to remember
@xfbs
xfbs / consumption.txt
Created September 8, 2011 10:06
consumption
Consumption affecting the environment
Today, overpopulation is a serious issue in the world. To feed everyone, we need to make enough food. To make food, we have to cut down forests to make space for cattle and crops. This causes some species like tigers to become extinct because their habitat has been used by us humans.
Also, many people drive cars, which release carbon dioxide. This is a chemical which influences the environment, causing global warming.
People use a lot of water; more than they actually need. This means that the groundwater levels are sinking and people are having trouble accessing water.
@xfbs
xfbs / gist:b67a195c5aef1bfa3a29
Created October 23, 2015 13:21 — forked from kcooper22/gist:2f5e7a66ce2846f2b709
Kyle Cooper WDI Week 04 Assessment
1. Can you execute Ruby in the Chrome console? Why / why not?
Ruby cannot be executed in the chrome console. I am not exectly sure the technical reasons, but I would guess is that chrome does not have an inheret Ruby envirement to execute the code. This is why we had to create the envirement on our local computers.
2. Write some Ruby code that includes a method that fails to work solely because of a scope issue. Think about how Ruby scope differs from Javascript scope.
array = [1,2]
def add
array[0]+array[1]
\begin{tikzpicture}[shorten >=1pt,auto]
%\node[state,initial,accepting] (0_A) {$\{0,A\}$};
%\node[state] (1_B) at (2,2) {$\{1,B\}$};
%\node[state,accepting] (4_A) [right of=1_B] {$\{4,A\}$};
%\node[state] (1_C) [below of=0_A] {$\{1,C\}$};
%\node[state,accepting] (2_A) [below of=1_B] {$\{2,A\}$};
%\node[state] (4_B) [below of=4_A] {$\{4,B\}$};
%\node[state] (2_C) [below of=1_C] {$\{2,C\}$};
%\node[state,accepting] (3_C) [below of=2_A] {$\{3,C\}$};
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1
mI0EVS40twEEAKZa444dPqVWtEEm7rXoYil+E2epwsHJFH21TEUh+EfWD1JWKdhs
rJn9+83n+CeSKu+fRAVaR/66CpqQ0SmkUew4tBTXZsm3zZNgxgMVDwzBHzup1ow1
umOIL7oWc4Aw+F5fPaAqHTw3+IBpavc+8wmdmV94nz3mLh5904pKMj67ABEBAAG0
Dmtra2trIDxrQGsua2s+iLgEEwECACIFAlUuNLcCGwMGCwkIBwMCBhUIAgkKCwQW
AgMBAh4BAheAAAoJEBreQ20puKF6AdMD/2mAaJJYBRdyZ6eDpldsAenkwVQoxDz8
a68auy9jLEA+jZH/y5pdlNGJ2uTUUdM00rYaV/oIzuxWLF1x7J8/qLD8rZQRKe3d
iKY6vq1L44cfmeSo5tN88h050fZCvqY+9sx3s1ubLztX5W8GzeDV0GBaORUulgwk
\renewcommand{\thesubsection}{Aufgabe H\arabic{section}\Alph{subsection}}
\renewcommand\thesection{Aufgabe H\arabic{section}}
\newcommand{\Aufgabe}[1]{\section{#1}}
\newcommand{\TeilAufgabe}[1]{\subsection{#1}}
\newcommand{\Loesung}{\subsubsection*{Lösung}}
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdbool.h>
#include <openssl/evp.h>
#include <openssl/err.h>
#include <openssl/rand.h>
#include <openssl/engine.h>
int main(int argc, char *argv[]) {
@xfbs
xfbs / list_test.c
Created November 26, 2016 17:50
tests for spp linked list
#include "list.h"
#include <assert.h>
#include <stdlib.h>
char *mystring = "my string";
char *otherstring = "other string";
int main(int argc, char *argv[])
{
LinkedList *lista, *listb;