Skip to content

These problems highlight the basic usage of arrays, pointers and structured programming.

License

Notifications You must be signed in to change notification settings

NushratJabenAurnima/Dynamic_Memory_Allocation_Arrays_Pointers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Problem 1

Write a program to find Largest Number Using Dynamic Memory Allocation from a list of elements. You have to input total size of elements and depending upon the number of elements, the required size has to be allocated using DMA. Example:

Input size of array: 5

Array element: 1 2 3 4 5

Expected Output: 5

Problem 2

Write a program to sort an array using Pointer. You have to write a function sortarray(int n, int * p) where n is the total array size and p is a pointer variable that have array address to solve the problem.

Input 5 number of elements in the array: 25 45 89 15 82

Expected Output: 15 25 45 82 89

Problem 3

Write a program that will delete all negative number by using Pointer. You have to declare a pointer array and dynamically allocate memory to input elements of array.

Problem 4

Write a program that will input student’s information (i.e. name, id, cgpa) who have enrolled for CSE-207 course in Summer 2020. You have to declare a pointer variable to input the information and dynamically allocate memory for storing information of each students. After taking input find out the student name who has obtained highest cgpa.

About

These problems highlight the basic usage of arrays, pointers and structured programming.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages