Skip to content

Instantly share code, notes, and snippets.

View Pompeu's full-sized avatar
:octocat:
Focusing

Itacir Ferreira Pompeu Pompeu

:octocat:
Focusing
  • PompeuSolutions
  • Buriti Alegre - GO
  • 02:37 (UTC -03:00)
View GitHub Profile
@Pompeu
Pompeu / gist:6b266ce8543be88f1ae8
Created August 22, 2014 13:50
chamano Funcion JS
var arquivo = require ('fs');
var path = './novo.txt';
arquivo.readFile('./clubes.txt',function(err,data){
if(err) throw err;
console.log(data.toString());
});
arquivo.exists(path,function(resultado){
if(!resultado){
#include <cstdio>
#include <cstdlib>
char* combina(char *a, char *b);
int main(){
int n;
scanf("%i ",&n);//esse espaço logo depois do %i limpa o buffer
@Pompeu
Pompeu / gist:55ef441683c62214e329
Created September 7, 2014 18:12
Classe JColorChoice
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package jpaint.view;
import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Font;
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package bntcolorchoise;
import java.awt.Color;
import java.awt.GridBagLayout;
import java.awt.event.ActionEvent;
@Pompeu
Pompeu / gist:9c4540abbe4f25fb66be
Created September 18, 2014 04:05
ClassJPAFigura
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package Model;
import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
@Pompeu
Pompeu / gist:e41b340ba540576a5321
Created September 21, 2014 17:02
Codigo Interessante
#include <iostream>
#include <sstream>
#include <fstream>
#include <string>
#include <vector>
#include <deque>
#include <queue>
#include <stack>
#include <set>
#include <map>
@Pompeu
Pompeu / gist:90cff5763b433906b659
Last active August 29, 2015 14:06
Arvores de Busca Binaria
/* URI Online Judge | 1195
**
** Árvore Binária de Busca
**
** By Itacir Ferreira Pompeu
**
** Instituto Federal Goiano Campus Morrinhos
*/
#include <cstdio>
@Pompeu
Pompeu / JSValidar
Last active August 29, 2015 14:08
JS
function validarForm(){
validarNome();
validarIdade();
validarEmail();
validarTelefone();
validarLinguasFaladas();
}
function validarNome(){
var nome = document.getElementById('formBase').nome.value;
if(nome.length > 0 || nome != null || nome != ''){
@Pompeu
Pompeu / NeoJ
Created October 24, 2014 02:54
NeoJ
var neo4j = require('neo4j');
var db = new neo4j.GraphDatabase('http://localhost:7474');
var node = db.createNode({hello: 'world'}); // instantaneous, but...
node.save(function (err, node) { // ...this is what actually persists.
if (err) {
console.error('Error saving new node to database:', err);
} else {
console.log('Node saved to database with id:', node.id);
}
List<String> listString = new ArrayList<>();
for(int i = 0 ; i < 10 ; i++){
listString.add("amor"+i);
}
ObservableList<String> obsList = FXCollections.observableArrayList(listString);
for (String obsList1 : obsList) {