将常用算法打印到命令行
项目描述
算法-CLI
将常用算法打印到命令行
指数
安装
使用点子:
$ pip install algocli
手动安装:
$ git clone https://github.com/emanuel2718/algocli.git
$ cd algocli
$ python setup.py install
描述
algocli是一个命令行工具,可让用户将常用算法直接打印到终端中。当您只需在终端中输入时,为什么要打开浏览器搜索无数关于如何在 python 中进行插入排序的文章。algocli python insertionsort
$ algocli [INPUT ...] [OPTIONS]
如何使用
选项:
-h, --help show this help message and exit
-v, --version displays the current version of algcli
--list-colors print list of available colorschemes
--list-lang print list of supported languages
--list-algo print list of supported algorithms
-c [COLORSCHEME], --color [COLORSCHEME]
colorized output
支持的语言:
必须给出正确的语言查询(如左侧所示),以便algocli理解
actionscript Actionscript
ada Ada
algol68 ALGOL68
applescript Applescript
autohotkey Autohotkey
awk AWK
c C
cpp C++
csharp C#
d D
delphi Delphi
fsharp F#
eiffel Eiffel
fortran Fortran
go Go
haskell Haskell
objc Objective-C
java Java
javascript Javascript
lua Lua
matlab Matlab
ocaml Ocaml
pascal Pascal
perl Perl
php PHP
powershell PowerShell
python Python
ruby Ruby
rust Rust
scala Scala
swift Swift
支持的算法:
必须给出正确的语言查询(如左侧所示),以便algocli理解
avltrees AVL Trees
b64 Decode Base64 data
beadsort Bead Sort algorithm
binarysearch Binary Search algorithm
bogosort Bogo Sort algorithm
bubblesort Bubble Sort algorithm
caesarcipher Caesar Cipher
cocktailsort Cocktail Sort algorithm
combsort Comb Sort algorithm
countingsort Counting Sort algorithm
cyclesort Cycle Sort algorithm
damm Damm algorithm
dijkstra Dijkstra algorithm
e Calculate the value of e
eulermethod Euler method
evolutionary Evolutionary algorithm
factorial Calculate factorials
factorions Calculate factorions
fft Fast Fourier Transforms
fib Fibonacci Sequence
fibnstep Fibonacci N-step Number Sequence
fileexists Check if a given file exists or not
fizzbuzz FizzBuzz
floydwarshall Floy Warshall algorithm
gnomesort Gnome Sort algorithm
hammingnumbers Hamming numbers
heapsort Heap Sort algorithm
huffman Huffman coding
insertionsort Insertion Sort algorithm
isaac ISAAC Cipher
knapsack Knapsack Problem 0-1
knapsackbound Knapsack Problem Bounded
knapsackcont Knapsack Problem Continous
knapsackunbound Knapsack Problem Unbounded
kolakoski Kolakoski Sequence
mandelbrot Mandelbrot Set
mazegen Maze Generation
mazesolve Maze Solving
md4 How to use MD4
md5 How to use MD5
md5imp MD5 Algorithm implementation
mergesort Merge Sort algorithm
nqueen N-Queens Problem
pancakesort Pancake Sort algorithm
patiencesort Patience Sort algorithm
permutationsort Permutation Sort algorithm
quickselect Quickselect Algorithm
quicksort Quick Sort algorithm
radixsort Radix Sort algorithm
recaman Recaman Sequence
regex Simple Regular Expressions
rot13 Rot-13 Algorithm
rsa RSA code
selectionsort Selection Sort algorithm
sexyprime Sexy primes
sha1 SHA-1 Algorithm
sha256 SHA-256 Algorithm
shellsort Shell Sort algorithm
sieve Sieve of Eratosthenes Algorithm
sleepsort Sleep Sort algorithm
stoogesort Stooge Sort algorithm
strandsort Strand Sort algorithm
subcipher Substitution Cipher
toposort Topological Sort Algorithm
例子
注意:选项的顺序无关紧要,但为了简单起见,所有示例都将首先显示算法,然后是语言。以下是等价的:
$ algocli radixsort cpp
$ algocli cpp radixsort
支持的语言列表
$ algocli --list-lang
支持的算法列表
$ algocli --list-algo
没有颜色的Python插入排序
$ algocli insertionsort python
使用带有颜色的 Python 进行插入排序
$ algocli insertionsort python -c
带有材料颜色方案的 Python 插入排序
$ algocli insertionsort python -c material
使用 C++ 进行基数排序
$ algocli radixsort cpp
使用 Java 计算斐波那契数列
$ algocli fib java
可用主题
贡献
在此处插入贡献信息
学分
如果没有Rosetta Code ,这个项目是不可能实现的,对于任何希望了解如何用几乎所有现有的编程语言做不同事情的程序员来说,这都是一个极好的资源。
所有学分都归于 Rosetta Code 和该站点的所有贡献者。
项目详情
下载文件
下载适用于您平台的文件。如果您不确定要选择哪个,请了解有关安装包的更多信息。
源分布
algocli-0.2.tar.gz
(14.3 kB
查看哈希)
内置分布
algocli-0.2-py3-none-any.whl
(12.5 kB
查看哈希)