This file contains 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
#A python script to generate prime numbers | |
def getfactors(n): | |
factors = [] | |
for num in range(1,n+1): | |
if n%num == 0: | |
factors.append(num) | |
return factors |
This file contains 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
#! /bin/python3 | |
''' | |
WRITTEN by Tushar Maharana | |
LICENSE: https://tusharhero.mit-license.org/ | |
Python program to find sum of all odd numbers between 1 to n. | |
''' | |
def is_it_odd(n):#checks if the input is odd |
This file contains 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
''' | |
WRITTEN by Tushar Maharana | |
LICENSE: https://tusharhero.mit-license.org/ | |
this script will sort any number list from smallest to largest | |
''' | |
def sortedone(list):#function to sort a list. | |
l = 0#counter | |
ll = 0# counter |
This file contains 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
''' | |
WRITTEN by Tushar Maharana | |
LICENSE: https://tusharhero.mit-license.org/ | |
“Code” Generator | |
Will take text and convert it into code (replace the letters) | |
''' | |
def c2l(s,dic):#this function will figure out the placement in dictionary | |
l = 0#variable will contain the placment in dictionary | |
while l < len(dic): #will break if l is more than the length of dictionary |
This file contains 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
#! /bin/python3 | |
''' | |
WRITTEN BY TUSHAR MAHARANA @tusharhero.github.io | |
Took 4 days pls do link me if you use this(highly unlikely) | |
have fun! | |
''' | |
''' | |
LICENSE: https://tusharhero.mit-license.org/ |
This file contains 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 os | |
a = 0 | |
dir = input('dir: ') | |
l = 10 | |
C=str(input('camera: ')or"0") | |
while a < l: | |
a = 1 + a | |
c = 'termux-camera-photo -c '+ C+" " + dir + str(a) + '.jpeg' | |
print(c) |