Skip to content
Programmingoneonone
Programmingoneonone
  • Home
  • CS Subjects
    • Internet of Things (IoT)
    • Digital Communication
    • Human Values
  • Programming Tutorials
    • C Programming
    • Data structures and Algorithms
    • 100+ Java Programs
    • 100+ C Programs
  • HackerRank Solutions
    • HackerRank Algorithms Solutions
    • HackerRank C problems solutions
    • HackerRank C++ problems solutions
    • HackerRank Java problems solutions
    • HackerRank Python problems solutions
Programmingoneonone

C++ program to find out the smaller number from the given numbers

YASH PAL, 31 July 202422 August 2024

In this post, we will write a C++ program to find out the smaller number from the given numbers.

C++ program to find out the smaller number from the given numbers

C++ program to find out the smaller number from the given numbers.

#include<iostream>
#include<conio.h>

void minint(int*, int);

int main()
{
    system("cls");

    int arr[10] = {15,2,3,4,5,10,9,8,7,6};
    minint(arr,10);
    getch();
}

void minint(int *arr, int m)
{
    int temp;
    temp = arr[0];

    for(int i=0;i<m;i++)
        if(arr[i] < temp)
            temp = arr[i];

    std::cout<<"The smallest value is = "<<temp;
}

Output

The smallest value is = 2
C++ Programming Tutorials coding problems solutions

Post navigation

Previous post
Next post

Pages

  • About US
  • Contact US
  • Privacy Policy

Programing Practice

  • C Programs
  • java Programs

HackerRank Solutions

  • C
  • C++
  • Java
  • Python
  • Algorithm

Other

  • Leetcode Solutions
  • Interview Preparation

Programming Tutorials

  • DSA
  • C

CS Subjects

  • Digital Communication
  • Human Values
  • Internet Of Things
  • YouTube
  • LinkedIn
  • Facebook
  • Pinterest
  • Instagram
©2025 Programmingoneonone | WordPress Theme by SuperbThemes