About 1,380,000 results
Open links in new tab
  1. shell script for multiplication table - Stack Overflow

    Apr 16, 2011 · Either change the first line of your script to: #!/bin/bash The Korn shell (at least some versions) and zsh also support the form of the for statement. If you're using the Bourne …

  2. Shell script to print table of a given number - GeeksforGeeks

    Jul 31, 2023 · In this article, we will explore the process of creating a simple yet powerful shell script that takes user input and generates number tables. Number tables are a common …

  3. 16 Examples of For Loop in Shell Script [Free Downloads]

    Mar 13, 2024 · For Loop Syntax in Bash Scripting; Shell Script Examples in Linux Using “for” Loop. Basic Shell Scripts With “for” Loop. Example 1: Print Numbers From 5 to 1; Example 2: …

  4. shell - using expr “multiplication table” - Unix & Linux Stack …

    Jan 1, 2017 · Yes, you can use bash's built-in Arithmetic Expansion $(( )) to do some simple maths. For Multiplication: Result. And your script would look like this: for j in 1 2 3 4 5 6 7 8 9. …

  5. For loop - Linux Bash Shell Scripting Tutorial Wiki - nixCraft

    Jul 17, 2017 · A representative example in BASH is as follows to display multiplication table with for loop (multiplication.sh): #!/bin/bash n = $1 # make sure command line arguments are …

  6. Dara433/Bash-Script-Multiplication-table - GitHub

    The objective of this project is to create a Bash script that generates a full multiplication table. The code features loops to generate muliplication table. The 2 different kinds used are list form and …

  7. [SOLVED] shell script with for loop multiplication of numbers

    Mar 20, 2014 · I am trying to create a script using for loop where the user gets prompted for a number. That number must then be multiplied by 1 through to 10 and displaying the answer …

  8. Print Multiplication table of any number | Unix programming

    Mar 27, 2021 · Now, apply while loop with condition ( 'i' less than equal to 10 ) Start the loop by ( do ) Store the result of multiplication of 'n' and 'i' in another variable 'res'

  9. How do I create a bash script, using loops, to create a Multiplication

    Mar 20, 2019 · Here is what I have: #!/bin/bash #create a multiplication table 5 columns 10 rows echo " Multiplication Table " echo "-----+-----" for x in {0..5} do for y in {0...

  10. How to Use Bash “for” Loop with Variable [12 Examples]

    Mar 17, 2024 · This script showcases a Bash implementation to generate a formatted multiplication table with a size of 5×10 within the shell interface, using nested “for” loops and …