The given problem asked in fico placement interview round. Find the gcd of two given numbers using shell scripting
We are given two numbers A and B and now task is to find the Greatest Common divisor (gcd) of two given number using shell scripting .
Asked in interview : FICO
Input 25 15 Output 5
This article is contributed by Ajay Puri. If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above.
- Introduction to Linux Shell and Shell Scripting
- How to find time taken by a command/program on Linux Shell?
- Making your own Linux Shell in C
- Developing a Linux based shell
- Basic Shell Commands in Linux
- How to Install Z Shell(zsh) on Linux?
- Getting System and Process Information Using C Programming and Shell in Linux
- Kali Linux - Terminal and Shell
- Leap Year Program with Bash Shell Scripting in Windows
- Bash shell script to find sum of digits
- Bash shell script to find out the largest value from given command line arguments
- Reverse a String | Shell Programming
- Array Basics Shell Scripting | Set 2 (Using Loops)
- Array Basics in Shell Scripting | Set 1
- Bash shell script to swap two numbers
- Looping Statements | Shell Script
- Conditional Statements | Shell Script
- String Operators | Shell Script
- Basic Operators in Shell Scripting
- Implementing Directory Management using Shell Script