View admin.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> //Pre-processor: Inclui biblioteca necessaria | |
#include <string.h> //Necessaria para o strcpy | |
#define ERROR_OPEN NULL | |
typedef struct //Cria tipo definido para estação | |
{ | |
char name[12]; //Char de 12 posições para armazenar o nome | |
int distance; //Inteiro para armazenar quilometros para a proxima estação | |
} tp_station; |
View AcademicSystem.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Cristina Silva <cristina.silva@openmailbox.org> | |
* GNU Public License | |
*/ | |
#include <stdio.h> | |
#include <stdbool.h> | |
#include <string.h> | |
#include <ctype.h> |
View ponteiro.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* ponteiro.c | |
* | |
* Copyright 2014 Cristina Silva <cristina.silva@openmailbox.org> | |
* | |
* This program is free software; you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation; either version 2 of the License, or | |
* (at your option) any later version. | |
* |
View error.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define SUCCESS 0 | |
#define NULL_ARGS 1 | |
#define NULL_PARAM -1 |
View StructDinamico.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <string.h> | |
#include <stdlib.h> | |
#define T_STRING 50 | |
// monta um registro de um aluno | |
struct Aluno{ | |
char nome[T_STRING]; | |
int nota[3]; | |
float media; | |
}; |
View index.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <!-- IE, sempre o IE --> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<title><!-- My title stay here! --></title> | |
<link rel="stylesheet" type="text/css" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css"> |
View manipula.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Declara função manipula que recebe listas que é uma lista de listas | |
#Por exemplo: listas = [['abaxai', 'goiaba', 'banana'], ['gol', 'celta', 'picasso'], ['cachorro', 'mamute', 'gato']] | |
def manipula(listas): | |
#Inicializa uma lista vazia | |
res = [] | |
#Inicia um laço de for que vai desde 0 até a última casa de listas | |
for i in range(len(listas)): #A função len(listas) retorna o tamanho de listas. Exemplo: len(['cachorro', 'mamute', 'gato']) = 3 | |
#Coloca numa variavel um elemento de listas indicado pelo indice i | |
lista = listas[i] # Por exemplo: lista = ['gol', 'celta', 'picasso'] | |
#Testa se o tamanho de lista é igual a 0, ou seja, uma lista vazia |
View Procfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
web: target/wildfly-8.2.0.Final/bin/standalone.sh -Djboss.http.port=$PORT -b 0.0.0.0 |
View .tmux.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# remap prefix to Control + a | |
set -g prefix C-a | |
# bind 'C-a C-a' to type 'C-a' | |
bind C-a send-prefix | |
unbind C-b |
View gist:14f5963e897bc0853c9a187a2c717acf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Party struct { | |
ID int `db:"id"` | |
Description string `db:"description"` | |
StartAt time.Time `db:"start_at"` | |
EndAt time.Time `db:"end_at"` | |
Dangerous bool `db:"dangerous"` | |
} |
OlderNewer