[Solved] ITDSIU19023 Lab 3

$25

File Name: ITDSIU19023_Lab_3.zip
File Size: 160.14 KB

SKU: [Solved] ITDSIU19023 Lab 3 Category: Tag:
5/5 - (1 vote)

From this lab onward, create one single .c file and use functions for the questions (e.g. ex01, ex02, for the function names)

  1. Input an array of n integers. Write a function to check whether the array is symmetric or not (optional: use recursive)

Example: 1 2 3 2 1 symmetric

  1. Input an array of n integers. Sort the odd numbers in increasing order and even numbers in decreasing order

Example: array = 2 5 3 4 8 6 7 9 2 result = 8 3 5 6 4 2 7 9 2

  1. Input an array of n integers. Find the largest sorted sub array (sorted array increasing/decreasing and has the largest number of elements)

Example: array = 2 5 3 4 8 9 7 6 10 result = 3 4 8 or 9 7 6

  1. Write a function to check whether a given array is sorted or not. Return 1 if sorted increasing, -1: decreasing, 0: not sorted
  2. Write a function to move all positive element of an array upfront

Example: 2 -3 4 6 -7 9 8 -2 2 4 6 9 8 -3 -7 -2

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] ITDSIU19023 Lab 3[Solved] ITDSIU19023 Lab 3
$25