Write a C++ program to implement Pascal’s triangle.


In mathematics, Pascal’s triangle is atriangular array of the binomial coefficients. In much of the Western world it is named after French mathematician Blaise Pascal, although other mathematicians studied it centuries before him in India, Iran, China, Germany, and Italy.   C++ Code: #include<iostream> using namespace std; int main() { int rows; cout << “Enter the number of rows : “; cin >> rows; cout … Continue reading Write a C++ program to implement Pascal’s triangle.

Write an Assembly Language Program to calculate String Distance.


Write an Assembly Language Program (ALP) to calculate String Distance. Write an 8086 assembly language program that takes 1 string as input and computes the string distance for that input. The distance of a string is the sum of the difference between the ASCII codes of consecutive characters of the string. As an example, assume the string input by the user is encs432, then the … Continue reading Write an Assembly Language Program to calculate String Distance.