Filter löschen
Filter löschen

for loop

1 Ansicht (letzte 30 Tage)
Baba
Baba am 14 Nov. 2011
i'd like to create 10 folders, named folder_1, folder_2....folder_10. Please help me fix the syntax.
for i=1:10
mkdir ('folder_',i) how do I properly use the i index in this case?
end

Akzeptierte Antwort

Grzegorz Knor
Grzegorz Knor am 14 Nov. 2011
for i=1:10
mkdir (sprintf('folder_%i',i))
end

Weitere Antworten (0)

Kategorien

Mehr zu Loops and Conditional Statements finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by