Shell Scripts



Write a shell script to count the number of occurrences of a particular digit in an 8 digit number input.






















Write a shell program to prepare electricity bill by entering meter number, previous reading and current meter reading. The amount is calculated based on the following conditions:If unit=0, then charge =40. If unit>0 and unit <=100 then charge=unit * 1. If unit>100 and unit <= 300 then charge=100+ (unit-100)*1. If unit>300, then charge=300+ (unit-300)*2. 

Write a Shell program to count the number of users who are currently logged in and display an appropriate message when a user logs in.

Write a Shell program to find n! / r!

Write a shell script to input two numbers m and n. Display the multiplication table of the number m up to n times.


No comments:

Post a Comment