Skip to content

Instantly share code, notes, and snippets.

@leandrovianna
leandrovianna / README.md
Last active September 17, 2020 06:33
EDA implementation in CUDA

Overview

The dataset of synonyms extracted from WordNet database version 3.0

License

WordNet License This license is available as the file LICENSE in any downloaded version of WordNet.

WordNet 3.0 license:

#include <GL/glut.h>
#include <stdio.h>
#include <math.h>
typedef GLfloat Matrix3x3[3][3];
const GLdouble pi = 3.14158;
typedef struct wcPt2D {
GLfloat x, y;
} wcPt2D;
#include <bits/stdc++.h>
using namespace std;
const int N = 1010;
set<int> g[N];
bool vis[N];
set<pair<int, int>> ss;
void dfs(int v) {
//URI Online Judge - Problema Fácil de Rujia Liu - 1424
#include <bits/stdc++.h>
using namespace std;
const int N = 1000100; // 10^6
vector<int> pos[N];
int main() {
ios::sync_with_stdio(false);
int n, m, x, v;
//URI Online Judge - Tradutor do Papai Noel - 1763
#include <bits/stdc++.h>
using namespace std;
map<string, string> FRASES = {
{ "brasil" , "Feliz Natal!" },
{ "alemanha" , "Frohliche Weihnachten!" },
{ "austria" , "Frohe Weihnacht!" },
{ "coreia" , "Chuk Sung Tan!" },
{ "espanha" , "Feliz Navidad!" },
#include <stdio.h>
#include <stdlib.h>
typedef struct cel{
int chave;
struct cel *esq;
struct cel *dir;
int bal;
}NO;
package main
import (
"fmt"
)
const N = 10
func Sqrt(x float64) float64 {
z := 1.0
@leandrovianna
leandrovianna / pipelight_install.sh
Created December 3, 2014 19:21
Shell Script para instalação do Pipelight com o Silverlight ativado no Debian Wheezy
#!/bin/bash
#obs.: executar esse script com permissões de root
#adicionando arquitetura i386
dpkg --add-architecture i386
cd /tmp
wget http://download.opensuse.org/repositories/home:/DarkPlayer:/Pipelight/Debian_7.0/Release.key
@leandrovianna
leandrovianna / transaction.java
Last active August 29, 2015 14:10
Transaction in Android (using SQLite)
db.beginTransaction(); //inicia a transação
try {
//operações de bancos são feitas aqui
//db.insert...
//caso o fluxo chegue aqui a transacao nao teve erros
//entao fazemos o commit da transacao
db.setTransactionSuccessful();
@leandrovianna
leandrovianna / .bashrc
Last active August 29, 2015 14:10
.bashrc for Debian Wheezy Colour Terminal
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
alias ls='ls --color=auto'