Skip to content

Latest commit

History

History
22 lines (16 loc) 路 412 Bytes

begin.md

File metadata and controls

22 lines (16 loc) 路 412 Bytes

begin

Description : This method returns an iterator pointing to the first element in the set.

Example :

//Run Code To Demonstrate use of set.begin()
#include<iostream>
#include<set>

int main(){
    // Create a set object holding integers
    std::set<int> mySet {1,2,3,4,-5};

    std::cout << *(mySet.begin()) <<std::endl;
    return 0;
}

Run Code