j
k
j a
j l
+# $1: order of pages +order_to_pages() +{ local pages=1 local order=$1 while [[ $order != 0 ]]; do order=$((order-1)) pages=$(($pages*2)) done echo $pages +}
+# $1: order of pages +order_to_pages() +{
order=$((order-1))
pages=$(($pages*2))
+}
For bash we can use $((2 ** $order)) to get the number..
Thanks Dave
Back to the thread
Back to the list