This file contains hidden or 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
¿Qué es Bitcoin? | |
---------------- | |
Bitcoin es una modena digital experimental que permite hacer pagos instantáneos | |
a cualquier persona, en cualquier parte del mundo. Bitcoin utiliza tecnología | |
p2p para operar sin una autoridad central: el procesamiento de transacciones y | |
la emisión de dinero se llevan a cabo en la red de forma colectiva. Bitcoin Core | |
es el nombre del software público que permite el uso de esta moneda. | |
Para más información lea el documento original de Bitcoin https://bitcoinwhitepaper.co/. |
This file contains hidden or 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
def ocho_reinas() | |
@reinas_en_tablero = [] | |
fila = 0 | |
columna = 0 | |
# hasta ubicar 8 reinas en el tablero | |
until @reinas_en_tablero.size == 8 | |
# si existe una reina en la fila o en una diagonal, se sigue con la otra fila | |
if reina_en_fila(fila) || reina_en_diagonal(fila, columna) |
This file contains hidden or 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
import RPi.GPIO as io | |
import time | |
# Establecemos el modo de referenciar los puertos | |
# Broadcom SOC channel | |
io.setmode(io.BCM) | |
# Desactivamos los mensajes de advertencias | |
io.setwarnings(False) | |
# Configuramos el puerto para el led |
This file contains hidden or 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
import RPi.GPIO as GPIO | |
import time | |
# Establecemos el modo de referenciar los puertos | |
# Broadcom SOC channel | |
GPIO.setmode(GPIO.BCM) | |
# Desactivamos los mensajes de advertencias | |
GPIO.setwarnings(False) | |
# Configuramos el puerto para el led |
This file contains hidden or 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
import RPi.GPIO as GPIO | |
import time | |
# Establecemos el modo de referenciar los puertos | |
# Broadcom SOC channel | |
GPIO.setmode(GPIO.BCM) | |
# Desactivamos los mensajes de advertencias | |
GPIO.setwarnings(False) | |
# Configuramos el puerto para el led |
This file contains hidden or 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
import smtplib | |
from email.mime.multipart import MIMEMultipart | |
from email.mime.text import MIMEText | |
from email.mime.base import MIMEBase | |
from email import encoders | |
# Iniciamos los parámetros del script | |
remitente = '[email protected]' | |
destinatarios = ['[email protected]', '[email protected]', '[email protected]'] | |
asunto = '[RPI] Correo de prueba' |
This file contains hidden or 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
import smtplib | |
from email.mime.multipart import MIMEMultipart | |
from email.mime.text import MIMEText | |
# Iniciamos los parámetros del script | |
remitente = '[email protected]' | |
destinatario = '[email protected]' | |
# Creamos el objeto mensaje | |
mensaje = MIMEMultipart() |
This file contains hidden or 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
import smtplib | |
# Creamos la conexión con el servidor | |
sesion_smtp = smtplib.SMTP('smtp.gmail.com', 587) | |
# Ciframos la conexión | |
sesion_smtp.starttls() | |
# Iniciamos sesión en el servidor | |
sesion_smtp.login('[email protected]','una contraseña segura') |
This file contains hidden or 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
before_filter :establecer_cabeceras_cors | |
def establecer_cabeceras_cors | |
headers['Access-Control-Allow-Origin'] = 'http://127.0.0.1:8100' | |
headers['Access-Control-Allow-Methods'] = 'GET,POST,PUT,DELETE' | |
headers['Access-Control-Allow-Headers'] = '*' | |
headers['Access-Control-Max-Age'] = '3628800' | |
end |
This file contains hidden or 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
No API style base was selected, see the Api Integration FAQ for more information on this warning | |
mercados.js:3 Supermercados: | |
(index):1 XMLHttpRequest cannot load http://localhost:3000/api/v1/supermercados. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:8100' is therefore not allowed access. |
NewerOlder