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
| int main() { | |
| // Definir los números | |
| int n1 = 10, n2 = 4, n3 = 6; | |
| // Calcular la media aritmética | |
| int media = (n1 + n2 + n3) / 3; | |
| // Código para el microcontrolador, para demostrar el resultado. | |
| DDRB |= (1 << PB5); // Establecer PB5 como salida | |
| while (1) { | |
| if (media >= 0 && media <= 255) { |
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
| main: | |
| ; Definir los números | |
| ldi r16, 2 ; n1 | |
| ldi r17, 4 ; n2 | |
| ldi r18, 6 ; n3 | |
| ; Calcular la media aritmética | |
| add r16, r17 ; r16 = n1 + n2 | |
| add r16, r18 ; r16 = n1 + n2 + n3 | |
| ldi r19, 3 ; divisor |
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
| #include <iostream> | |
| int main() { | |
| int n1 = 2; | |
| int n2 = 4; | |
| int n3 = 0; | |
| if (n1 == n2) { | |
| n3 = 1; | |
| } else { | |
| n3 = 0; |
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
| ; numeros_iguales.asm | |
| ; | |
| ; Created: 19/4/2024 07:53:30 | |
| ; Author : Alejandro Velasco | |
| ; | |
| ; Replace with your application code | |
| start: | |
| .include "m328Pdef.inc" |
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 read_txt_file_from_attached_file(file_url=None, fcontent=None, filepath=None): | |
| if file_url: | |
| _file = frappe.get_doc("File", {"file_url": file_url}) | |
| filename = _file.get_full_path() | |
| txtrs = open(filename) | |
| #si es txt | |
| #rs = txtrs.readlines() | |
| #si es json | |
| rs = json.loads(txtrs) | |
| return rs |
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 pandas as pd | |
| ruta_archivo = r"Punto_nuevo_CRM.xlsx" | |
| nombre_hoja = "Result 1" | |
| def extraer_data(nombre_hoja): | |
| df = pd.read_excel(ruta_archivo, sheet_name=nombre_hoja) | |
| return df |