Skip to content

aliiii786/array-shop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

array-shop

Array Shop – C Programming Project Project Description

Array Shop is a menu-driven C program that allows users to perform multiple operations on arrays. The program provides tools to create, analyze, search, manipulate, and evaluate array elements.

This project demonstrates fundamental C programming concepts such as arrays, functions, loops, pointers, and algorithm implementation.

It is designed as a practice project for beginners learning Data Structures and C programming.

Features

The program provides the following operations:

1 Create Array

Allows the user to enter elements into the array.

2 Display Array

Displays all elements stored in the array.

3 Reverse Array

Displays the array elements in reverse order.

4 Maximum Element

Finds the largest element in the array.

5 Minimum Element

Finds the smallest element in the array.

6 Sum of Array

Calculates the sum of all array elements.

7 Average of Array

Calculates the average value of array elements.

8 Percentage Calculation

Calculates percentage assuming each element represents marks out of 100.

9 Grade Calculation

Grades are assigned based on percentage.

Percentage Grade 90 – 100 A+ 80 – 90 A 70 – 80 B+ 60 – 70 B 50 – 60 C 40 – 50 D 33 – 40 E Below 33 Fail

12 Second Largest Element

Finds the second largest number in the array.

11 Reverse Array by Swapping

Reverses the array using element swapping.

12 Linear Search

Searches for an element and returns its index position.

13 Array Rotation (Shift)

Rotates the array by a specified number of steps using the reverse algorithm.

14 Palindrome Check

Checks whether the array reads the same forward and backward.

Example:

1 2 3 2 1 → Palindrome

15 Duplicate Check

Displays duplicate elements present in the array.

Concepts Used

This project demonstrates:

Arrays

Functions

Pointers

Menu Driven Programming

Searching Algorithms

Array Manipulation Algorithms

Conditional Statements

Looping Structures

⚙️ How to Compile and Run Step 1: Compile the program gcc arrayshop.c -o arrayshop Step 2: Run the program ./arrayshop 📋 Example Program Menu WELCOME TO ARRAY SHOP

  1. Create a array
  2. Display a array
  3. Reverse a array
  4. Maximum Element in array
  5. Minimum Element in array
  6. Sum of the full Array
  7. Average of a array
  8. Percentage of array
  9. Grade
  10. Greatest Second Integer
  11. Swapping Array
  12. Linear Search
  13. Shift by your choice
  14. Palindrome check
  15. Check Duplicate Learning Outcomes

By completing this project, you will learn:

How to design menu-driven programs

How to work with arrays and pointers

How to implement searching algorithms

How to perform array transformations

How to organize programs using multiple functions

👨‍💻 Author Ali Rizvi C Programming Student Array Shop Project

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages