Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 001 Write function void print_fact(unsigned char n), which prints "fact(n) = X". For computing and printing use functions factorial and printf.
- 002 Create a field (using a malloc call from C language) of n size of short elements, where n is a constant. Write int avg (unsigned int n) function to calculate the arithmetic average of the numbers in this field. Try that it works correctly for both positive and negative numbers (including their mix).
- 003 Write in Assembly function : int perimeter_of_rectangle (int a, int b), which calculates perimeter of rectangle.
- 004 Write in Assembly function : int area_of_square (int a) that calculates the area of square.
- 005 Write function int positive (int a, int b, int c), which returns 1 if all arguments are positive, otherwise 0.
- 006 Write function char *my_strdup(char *s) which creates copy of provided string (use malloc and strlen from C++)
- 007 Create a static field of 10 int elements. Write function void multiples(short n), which stores multiples of n in the field.
- 008 Write in Assembly function : int area_of_rectangle (int a, int b) that calculates the area of rectangle.
- 009 Write the function short avg_short (short a, short b, short c) to calculate the average value of these three short numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 010 Create a static field of 10 short elements. Write the function void powers (), which will store numbers 1 to power of 2, 2 to power of 2, ..., 10 to power of 2 in the field.
- 011 Write in Assembly function : int perimeter_of_triangle4 (int a, int h), which calculates perimeter of triangle from side length and height.
- 012 Write function unsigned int fib(unsigned short n), which recursively computes n-th fibonacci number.
- 013 Create a static field of 10 int elements. Write function void countdown () , which stores a sequence of 10, 9, 8, ..., 1 (in this order) into the field.
- 014 Write function int avg_int (int a, int b, int c) to calculate the average value of these three int numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 015 Create a field (using a malloc call from C) of 10 int types. Write the function void powers2(), which will store numbers 2 to the power of 0, 2 to the power of 1, ..., 2 to the power of 9 in the field.
- 016 Write function int min3 function (unsigned char a, short b, int c) that returns the smallest value from these three passed parameters.
- 017 Write in Assembly function : int perimeter_of_triangle3 (int a, int b), which calculates perimeter of rectangular triangle.
- 018 Write function int power(int n, unsigned int m) returning the n to the power of m
- 019 Write in Assembly function : int area_of_cube (int a), which calculates area of cube.
- 020 Write function int factorial(int n) that recursively computes factorial of n
- 021 Write a program that calculates the content of the triangle according to the Heron formula: P = sqrt (s * (s-a) * (s-b) * (s-c)), s = (a + b + c) / 2. Enter to the program a, b, c (in C language), then the calculation is done in the Assembler to the final sqrt operation, which you execute using the sqrt function in C (you must insert the math.h header file).Write the result (using printf in C).
- 022 Write in Assembly function : int perimeter_of_square (int a), which calculates perimeter of square.
- 023 Write in Assembly function : int perimeter_of_triangle (int a, int b, int c), which calculates perimeter of triangle.
- 024 Write function int sgn (int i), which returns values -1, 0, 1, depending on whether the value is negative, zero or positive.
- 025 Write int minimum () function that returns the smallest array element. In the body of this function in C, create a local variable of the field type of the size of 10 int elements from which the values will be selected. Try that the function works correctly for both positive and negative numbers.
- 026 Write in Assembly function : int perimeter_of_triangle2 (int a), which calculates perimeter of equilateral triangle
- 027 Write function void print_fact(unsigned char n), which prints "fact(n) = X". For computing and printing use functions factorial and printf.
- 028 Write function int avg_int (int a, int b, int c) to calculate the average value of these three int numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 029 Write in Assembly function : int perimeter_of_triangle3 (int a, int b), which calculates perimeter of rectangular triangle.
- 030 Create a static field of 10 int elements. Write function void multiples(short n), which stores multiples of n in the field.
- 031 Write in Assembly function : int area_of_cube (int a), which calculates area of cube.
- 032 Write in Assembly function : int perimeter_of_square (int a), which calculates perimeter of square.
- 033 Write in Assembly function : int area_of_rectangle (int a, int b) that calculates the area of rectangle.
- 034 Create a field (using a malloc call from C) of 10 int types. Write the function void powers2(), which will store numbers 2 to the power of 0, 2 to the power of 1, ..., 2 to the power of 9 in the field.
- 035 Write function char *my_strdup(char *s) which creates copy of provided string (use malloc and strlen from C++)
- 036 Create a static field of 10 int elements. Write function void countdown () , which stores a sequence of 10, 9, 8, ..., 1 (in this order) into the field.
- 037 Write int minimum () function that returns the smallest array element. In the body of this function in C, create a local variable of the field type of the size of 10 int elements from which the values will be selected. Try that the function works correctly for both positive and negative numbers.
- 038 Write function unsigned int fib(unsigned short n), which recursively computes n-th fibonacci number.
- 039 Write in Assembly function : int perimeter_of_triangle4 (int a, int h), which calculates perimeter of triangle from side length and height.
- 040 Write in Assembly function : int perimeter_of_rectangle (int a, int b), which calculates perimeter of rectangle.
- 041 Write a program that calculates the content of the triangle according to the Heron formula: P = sqrt (s * (s-a) * (s-b) * (s-c)), s = (a + b + c) / 2. Enter to the program a, b, c (in C language), then the calculation is done in the Assembler to the final sqrt operation, which you execute using the sqrt function in C (you must insert the math.h header file).Write the result (using printf in C).
- 042 Write in Assembly function : int area_of_square (int a) that calculates the area of square.
- 043 Write function int power(int n, unsigned int m) returning the n to the power of m
- 044 Write in Assembly function : int perimeter_of_triangle2 (int a), which calculates perimeter of equilateral triangle
- 045 Create a static field of 10 short elements. Write the function void powers (), which will store numbers 1 to power of 2, 2 to power of 2, ..., 10 to power of 2 in the field.
- 046 Create a field (using a malloc call from C language) of n size of short elements, where n is a constant. Write int avg (unsigned int n) function to calculate the arithmetic average of the numbers in this field. Try that it works correctly for both positive and negative numbers (including their mix).
- 047 Write the function short avg_short (short a, short b, short c) to calculate the average value of these three short numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 048 Write function int positive (int a, int b, int c), which returns 1 if all arguments are positive, otherwise 0.
- 049 Write function int min3 function (unsigned char a, short b, int c) that returns the smallest value from these three passed parameters.
- 050 Write function int factorial(int n) that recursively computes factorial of n
- 051 Write in Assembly function : int perimeter_of_triangle (int a, int b, int c), which calculates perimeter of triangle.
- 052 Write function int sgn (int i), which returns values -1, 0, 1, depending on whether the value is negative, zero or positive.
- 053 Write function int positive (int a, int b, int c), which returns 1 if all arguments are positive, otherwise 0.
- 054 Create a field (using a malloc call from C) of 10 int types. Write the function void powers2(), which will store numbers 2 to the power of 0, 2 to the power of 1, ..., 2 to the power of 9 in the field.
- 055 Write in Assembly function : int perimeter_of_rectangle (int a, int b), which calculates perimeter of rectangle.
- 056 Write int minimum () function that returns the smallest array element. In the body of this function in C, create a local variable of the field type of the size of 10 int elements from which the values will be selected. Try that the function works correctly for both positive and negative numbers.
- 057 Write function int power(int n, unsigned int m) returning the n to the power of m
- 058 Write in Assembly function : int perimeter_of_triangle3 (int a, int b), which calculates perimeter of rectangular triangle.
- 059 Write function char *my_strdup(char *s) which creates copy of provided string (use malloc and strlen from C++)
- 060 Write in Assembly function : int area_of_rectangle (int a, int b) that calculates the area of rectangle.
- 061 Write in Assembly function : int area_of_cube (int a), which calculates area of cube.
- 062 Create a static field of 10 short elements. Write the function void powers (), which will store numbers 1 to power of 2, 2 to power of 2, ..., 10 to power of 2 in the field.
- 063 Create a static field of 10 int elements. Write function void multiples(short n), which stores multiples of n in the field.
- 064 Write function int sgn (int i), which returns values -1, 0, 1, depending on whether the value is negative, zero or positive.
- 065 Create a static field of 10 int elements. Write function void countdown () , which stores a sequence of 10, 9, 8, ..., 1 (in this order) into the field.
- 066 Write in Assembly function : int perimeter_of_triangle4 (int a, int h), which calculates perimeter of triangle from side length and height.
- 067 Write in Assembly function : int perimeter_of_triangle2 (int a), which calculates perimeter of equilateral triangle
- 068 Write function void print_fact(unsigned char n), which prints "fact(n) = X". For computing and printing use functions factorial and printf.
- 069 Write function int avg_int (int a, int b, int c) to calculate the average value of these three int numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 070 Write in Assembly function : int perimeter_of_triangle (int a, int b, int c), which calculates perimeter of triangle.
- 071 Write function int factorial(int n) that recursively computes factorial of n
- 072 Write a program that calculates the content of the triangle according to the Heron formula: P = sqrt (s * (s-a) * (s-b) * (s-c)), s = (a + b + c) / 2. Enter to the program a, b, c (in C language), then the calculation is done in the Assembler to the final sqrt operation, which you execute using the sqrt function in C (you must insert the math.h header file).Write the result (using printf in C).
- 073 Create a field (using a malloc call from C language) of n size of short elements, where n is a constant. Write int avg (unsigned int n) function to calculate the arithmetic average of the numbers in this field. Try that it works correctly for both positive and negative numbers (including their mix).
- 074 Write function int min3 function (unsigned char a, short b, int c) that returns the smallest value from these three passed parameters.
- 075 Write in Assembly function : int perimeter_of_square (int a), which calculates perimeter of square.
- 076 Write in Assembly function : int area_of_square (int a) that calculates the area of square.
- 077 Write the function short avg_short (short a, short b, short c) to calculate the average value of these three short numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 078 Write function unsigned int fib(unsigned short n), which recursively computes n-th fibonacci number.
- 079 Write in Assembly function : int perimeter_of_triangle3 (int a, int b), which calculates perimeter of rectangular triangle.
- 080 Write in Assembly function : int perimeter_of_rectangle (int a, int b), which calculates perimeter of rectangle.
- 081 Write in Assembly function : int area_of_rectangle (int a, int b) that calculates the area of rectangle.
- 082 Write in Assembly function : int perimeter_of_triangle4 (int a, int h), which calculates perimeter of triangle from side length and height.
- 083 Write function int power(int n, unsigned int m) returning the n to the power of m
- 084 Write in Assembly function : int area_of_cube (int a), which calculates area of cube.
- 085 Write function int avg_int (int a, int b, int c) to calculate the average value of these three int numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 086 Write function int positive (int a, int b, int c), which returns 1 if all arguments are positive, otherwise 0.
- 087 Write in Assembly function : int perimeter_of_triangle2 (int a), which calculates perimeter of equilateral triangle
- 088 Create a static field of 10 short elements. Write the function void powers (), which will store numbers 1 to power of 2, 2 to power of 2, ..., 10 to power of 2 in the field.
- 089 Write function unsigned int fib(unsigned short n), which recursively computes n-th fibonacci number.
- 090 Create a static field of 10 int elements. Write function void countdown () , which stores a sequence of 10, 9, 8, ..., 1 (in this order) into the field.
- 091 Write function char *my_strdup(char *s) which creates copy of provided string (use malloc and strlen from C++)
- 092 Write function int min3 function (unsigned char a, short b, int c) that returns the smallest value from these three passed parameters.
- 093 Write a program that calculates the content of the triangle according to the Heron formula: P = sqrt (s * (s-a) * (s-b) * (s-c)), s = (a + b + c) / 2. Enter to the program a, b, c (in C language), then the calculation is done in the Assembler to the final sqrt operation, which you execute using the sqrt function in C (you must insert the math.h header file).Write the result (using printf in C).
- 094 Write in Assembly function : int area_of_square (int a) that calculates the area of square.
- 095 Write function void print_fact(unsigned char n), which prints "fact(n) = X". For computing and printing use functions factorial and printf.
- 096 Write function int factorial(int n) that recursively computes factorial of n
- 097 Write the function short avg_short (short a, short b, short c) to calculate the average value of these three short numbers. Try that it works correctly for both positive and negative numbers (including their mix).
- 098 Create a field (using a malloc call from C language) of n size of short elements, where n is a constant. Write int avg (unsigned int n) function to calculate the arithmetic average of the numbers in this field. Try that it works correctly for both positive and negative numbers (including their mix).
- 099 Write in Assembly function : int perimeter_of_square (int a), which calculates perimeter of square.
- 100 Write int minimum () function that returns the smallest array element. In the body of this function in C, create a local variable of the field type of the size of 10 int elements from which the values will be selected. Try that the function works correctly for both positive and negative numbers.
- 101 Create a field (using a malloc call from C) of 10 int types. Write the function void powers2(), which will store numbers 2 to the power of 0, 2 to the power of 1, ..., 2 to the power of 9 in the field.
- 102 Write function int sgn (int i), which returns values -1, 0, 1, depending on whether the value is negative, zero or positive.
- 103 Create a static field of 10 int elements. Write function void multiples(short n), which stores multiples of n in the field.
- 104 Write in Assembly function : int perimeter_of_triangle (int a, int b, int c), which calculates perimeter of triangle.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement