Skip to content

Instantly share code, notes, and snippets.

Carlos J. Peláez Rivas cjpelaezrivas

View GitHub Profile
@cjpelaezrivas
cjpelaezrivas / PracticaNFT.sol
Created Mar 14, 2019
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.4+commit.9549d8ff.js&optimize=false&gist=
View PracticaNFT.sol
pragma solidity ^0.5.2;
/**
* @title IERC165
* @dev https://eips.ethereum.org/EIPS/eip-165
*/
interface IERC165 {
/**
* @notice Query if a contract implements an interface
* @param interfaceId The interface identifier, as specified in ERC-165
@cjpelaezrivas
cjpelaezrivas / CasaApuestas.sol
Created Mar 12, 2019
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.4+commit.9549d8ff.js&optimize=false&gist=
View CasaApuestas.sol
pragma solidity ^0.5.4;
contract Oraculo {
function consultar(uint partido) public returns(uint, uint) { }
}
contract CasaApuestas {
struct Apuesta {
address payable usuario;
@cjpelaezrivas
cjpelaezrivas / Banco.sol
Created Mar 11, 2019
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.4+commit.9549d8ff.js&optimize=false&gist=
View Banco.sol
pragma solidity ^0.5.4;
contract Banco {
struct Cliente {
uint balance;
uint adeudado;
}
uint constant limitePrestamo = 50; // Un usuario puede pedir hasta el 50% del saldo actual de su cuenta
@cjpelaezrivas
cjpelaezrivas / Agenda.sol
Created Mar 7, 2019
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.5.4+commit.9549d8ff.js&optimize=false&gist=
View Agenda.sol
pragma solidity ^0.5.4;
contract Agenda {
struct Contacto {
string nombre;
uint telefono;
string email;
}
View PlantillaLecturaEscritura.java
/*
* Lázarus Surazal
* 07 de Agosto de 2014
*/
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
You can’t perform that action at this time.