Note: You will need to have Python 3 and Rust installed on your computer!
To check how many iterations a number takes to reach 1, run the number_of_iterations.py file as follows:
python3 number_of_iterations.py
Output:
| #!/bin/bash | |
| # Function to increment version | |
| increment_version() { | |
| local version=$1 | |
| local increment_type=${2:-patch} | |
| IFS='.' read -ra version_parts <<< "$version" | |
| case $increment_type in |
| import logging | |
| import os | |
| from pathlib import Path | |
| class FileOperationError(Exception): | |
| """Custom exception for file operations.""" | |
| class FileHelper: |
| {"0":"-----","1":".----","2":"..---","3":"...--","4":"....-","5":".....","6":"-....","7":"--...","8":"---..","9":"----.","A":".-","B":"-...","C":"-.-.","D":"-..","E":".","F":"..-.","G":"--.","H":"....","I":"..","J":".---","K":"-.-","L":".-..","M":"--","N":"-.","O":"---","P":".--.","Q":"--.-","R":".-.","S":"...","T":"-","U":"..-","V":"...-","W":".--","X":"-..-","Y":"-.--","Z":"--..",".":".-.-.-",",":"--..--","?":"..--..","'":".----.","!":"-.-.--","/":"-..-.","(":"-.--.",")":"-.--.-","&":".-...",":":"---...",";":"-.-.-.","=":"-...-","+":".-.-.","-":"-....-","_":"..--.-","\"":".-..-.","$":"...-..-","@":".--.-.","¿":"..-.-","¡":"--...-"} |
| import cv2 | |
| from moviepy.video.compositing.CompositeVideoClip import CompositeVideoClip | |
| from moviepy.video.VideoClip import ImageClip, TextClip | |
| img = cv2.imread("input.png") | |
| img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB) | |
| vid = ImageClip(img) | |
| frame_height = img.shape[0] |
| import json | |
| data = {} | |
| with open("timedtext.json") as file: | |
| data = json.load(file) | |
| def extract_text(data): | |
| strings = [] |
| #include <iostream> | |
| int main() { | |
| int a = 7; | |
| int b = 5; | |
| std::cout << "Before: a=" << a << ", b=" << b << "\n"; | |
| a += b; | |
| b = a - b; |
Note: You will need to have Python 3 and Rust installed on your computer!
To check how many iterations a number takes to reach 1, run the number_of_iterations.py file as follows:
python3 number_of_iterations.py
Output:
| #[derive(Debug, Clone, Copy)] | |
| enum Bit { | |
| ZERO, | |
| ONE, | |
| } | |
| impl Bit { | |
| fn nand(self, other: Self) -> Self { | |
| match self { | |
| Self::ONE => match other { |
| use std::fmt; | |
| use std::ops; | |
| #[derive(Copy, Clone)] | |
| pub struct Complex { | |
| pub real: f64, | |
| pub imag: f64, | |
| } | |
| impl Complex { |
| import random | |
| lower_bound = 0 | |
| upper_bound = 100 | |
| random_number = int | |
| guess_count = 1 | |
| print('Think of a number between 0-100 in your head, and I will try to guess it.') | |
| print('Enter C for correct, L if it is lower and H if it is higher.') |