Note that there are some explanatory texts on larger screens.

plurals
  1. POlooping 1, 2 and 3 numbers
    primarykey
    data
    text
    <p>supposed to be I have 3 filenames</p> <p>file-00 file-01 file-02</p> <p>I'm trying to replicate those files to file-03, file-04, file-05...file-98, file-99, file-100 based on the original files.</p> <p>So in bash I do</p> <pre><code>#!/bin/bash x=0 y=1 z=2 for i in $(seq 0 100); do cp file-00 file-$((x=x+2)); cp file-01 file-$((y=y+3)); cp file-02 file=$((z=z+4)); done </code></pre> <p>but this doesn't work and it gives me the following output. which I only need a sequence of 100 numbers.</p> <pre><code>x=2 y=3 z=4 x=4 y=6 z=8 x=6 y=9 z=12 x=8 y=12 z=16 x=10 y=15 z=20 x=12 y=18 z=24 x=14 y=21 z=28 x=16 y=24 z=32 x=18 y=27 z=36 x=20 y=30 z=40 x=22 y=33 z=44 x=24 y=36 z=48 x=26 y=39 z=52 x=28 y=42 z=56 x=30 y=45 z=60 x=32 y=48 z=64 x=34 y=51 z=68 x=36 y=54 z=72 x=38 y=57 z=76 x=40 y=60 z=80 x=42 y=63 z=84 x=44 y=66 z=88 x=46 y=69 z=92 x=48 y=72 z=96 x=50 y=75 z=100 x=52 y=78 z=104 x=54 y=81 z=108 x=56 y=84 z=112 x=58 y=87 z=116 x=60 y=90 z=120 x=62 y=93 z=124 x=64 y=96 z=128 x=66 y=99 z=132 x=68 y=102 z=136 x=70 y=105 z=140 x=72 y=108 z=144 x=74 y=111 z=148 x=76 y=114 z=152 x=78 y=117 z=156 x=80 y=120 z=160 x=82 y=123 z=164 x=84 y=126 z=168 x=86 y=129 z=172 x=88 y=132 z=176 x=90 y=135 z=180 x=92 y=138 z=184 x=94 y=141 z=188 x=96 y=144 z=192 x=98 y=147 z=196 x=100 y=150 z=200 x=102 y=153 z=204 x=104 y=156 z=208 x=106 y=159 z=212 x=108 y=162 z=216 x=110 y=165 z=220 x=112 y=168 z=224 x=114 y=171 z=228 x=116 y=174 z=232 x=118 y=177 z=236 x=120 y=180 z=240 x=122 y=183 z=244 x=124 y=186 z=248 x=126 y=189 z=252 x=128 y=192 z=256 x=130 y=195 z=260 x=132 y=198 z=264 x=134 y=201 z=268 x=136 y=204 z=272 x=138 y=207 z=276 x=140 y=210 z=280 x=142 y=213 z=284 x=144 y=216 z=288 x=146 y=219 z=292 x=148 y=222 z=296 x=150 y=225 z=300 x=152 y=228 z=304 x=154 y=231 z=308 x=156 y=234 z=312 x=158 y=237 z=316 x=160 y=240 z=320 x=162 y=243 z=324 x=164 y=246 z=328 x=166 y=249 z=332 x=168 y=252 z=336 x=170 y=255 z=340 x=172 y=258 z=344 x=174 y=261 z=348 x=176 y=264 z=352 x=178 y=267 z=356 x=180 y=270 z=360 x=182 y=273 z=364 x=184 y=276 z=368 x=186 y=279 z=372 x=188 y=282 z=376 x=190 y=285 z=380 x=192 y=288 z=384 x=194 y=291 z=388 x=196 y=294 z=392 x=198 y=297 z=396 x=200 y=300 z=400 x=202 y=303 z=404 </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload