Tag: Lab programs
C Program to copy the content of file to another
Problem Statement Write a program in C to copy the content of one file to another. How to copy the content of the file to another using C ?
C Program to sort the numbers in descending order
Problem Statement Write a program in C to sort the given numbers in descending order. How to sort the number in descending order in C ?
C Program to a print pascal triangle
Problem Statement Write a program in C to print pascal triangle. How to print a pascal triange in C ?
C Program to delete an element from an array
Problem Statement Write a program in C to delete an element from an array. How to delete an element from an array in C ?
C# Program to display "Hello, World!"
Problem Statement Write a program in Visual C# to print Hello World in the console Window. How to display Hello World in C# ? Output Hello, World!
C Program to find the size of the array
Problem Statement Write a program in C to find the array size. How to find the size of the array in C ?
C Program to find square and cube of given number
Problem Statement You need to write a program in C to find the square and cube of a given number. Solution
C Program to search a number in an array
Problem Statement Write a program in C to search for a given number within the array. How to search for an given number in an array ?
C Program to sort numbers in ascending order
Problem Statement You need to write a program in C to sort the given numbers in ascending order. How to sort numbers in ascending order in C ?
C Program to generate random numbers
Problem Statement Write a program in C to generate 10 random number between 1 and 100. C Program to generate random numbers
C Program to convert uppercase string to lower case
Problem Statement Write a program in C to convert the given string from upper case to lower case. How to convert a upper case string to lower case string in C ?
C Program to insert an element into an array
Problem Statement Write a program in C to insert an element in to an array. C Program to insert an element into an array
System Software – SIC/XE Program to write a subroutine for SIC that will read a record into a buffer
Problem Statement Write a subroutine for SIC that will read a record into a buffer. The record may be any length from 1 to 100 bytes. The end of record is marked with a “null” character (ASCII code 00). The subroutine should place the length of the record read into a variable named LENGTH. Solution Line Number Code Comments 1 RDREC LDX ZERO 2…
C Program to find if the given number is a Strong Number or not.
Problem Statement You need to write a program in C to find if the given number is a strong number or not. How to find if the given number is a strong number ? What is a strong number ? A number is said to be a strong number when the sum of the factorial of a number’s individual digits are equal to the number…
C Program to compare arrays
Problem Statement You need to write a program in C to compare two arrays of characters and display if they are equal or not. How to compare two arrays in C ?
C Program to convert lower case string to upper case
Problem Statement Write a program in C to convert the given string from lower case to upper case. How to convert a lower case string to upper case string in C ?
C Program to check number is perfect number or not
Problem Statement Write a program in C to find if the given number is a perfect number or not. A number is said to be a perfect number if it is a positive number and when the sum of its divisors are equal to the number. How to find if the number is a perfect number or not ?
Finding Factorial of a Number using Function Delegates in C#
Below is a sample code snippet demonstrating the use of function delegates in C# to find the factorial of the number. How to find the factorial of a Number using Function Delegates in C# ?
C program to compare 2 numbers using ternary operator
Problem Statement Write a program in C to compare 2 numbers without using if statement but instead use the ternary operator. C program to compare 2 numbers using ternary operator
C Program to find the simple and compound interest
Problem Statement You need to find the simple and the compound interest for the given principal , time and rate of interest. How to find the simple and compound interest in C ?