Absolute value (abs) :-  


This function is used to absolute value of a numbers. The absolute means positive value. 

 
#include<iostream.h>

#include<conio.h>

#include<math.h>

Void main ()

{

Clrscr();

Float a, res;

Cout<<"Enter value for a";

Cin>>a;

res=abs (a) ;

Cout<<"result is"<<res;

getch();

}
               

Note:-  abs is used only for numeric value. 



πŸ‘‰Output:- 


Input is :   Enter value for a 5.6

Output is :-  5
                    

 Input is : Enter value for a 7.9

 Output is:   7


Absolute value (fabs)


This function  is used to find the absolute value of decimal variables. 

Syntax :-



#include<iostream.h>
#include<conio.h>
#include<math.h>
Void main()
{
Clrscr();
Float a, res;
Cout<<"Enter value for a";
Cin>>a;
res=fabs(a) ;
Cout<<"Result is"<<res;
getch() ;
}
  

πŸ‘‰Output:- 


Input :- Enter value for a  -9

Output:-   9

Input :-  Enter value for a  -4

Output:-    4



Floor (value) 



This function is round down value. 
  

#include<iostream.h>
#include<conio.h>
#include<math.h>
Void main () 
{
Clrscr() ;
Float  a, res;
Cout<<"Enter value for a":
Cin>>a;
res=floor(a);
Cout<<"Result is "<<res;
Getch();
}


πŸ‘‰Output :-



   Input :- Enter value for  a  6.6

   Output:-   6



    Input :-   Enter value for a 4.5

    Output:-  4




Ceil (value)


  This function round up the  nearest numberic number value. 


#include<iostream.h>
#include<conio.h>
#include<math.h>
Void main () 
{
Clrscr();
Float a, res;
Cout<<" Enter value for a ";
Cin>>a;
res=ceil (a) ;
Cout<<"Result is"<<res;
Getch() ;
}


πŸ‘‰Output:-  



Input :-   Enter value for a 5.9

Output:-      6


Input :-  Enter value for a 4.7

Output:-       5


Fmod (divident and divider) 


  This function is used to remainder of decimal value. 


#include<iostream.h>
#include<conio.h>
#include<math.h>
Void main () 
{
Clrscr() ;
Float a, res;
Cout<<"Enter value for a";
Cin>>a;
res=F mod (a, 5) ;
Cout<<"Result is "<<res;
Getch() ;
}


πŸ‘‰Output:-    



 Input :-Enter value for a  13

 Output:-    1


Input :-Enter value for a 21

Output:-     2
    

  After understanding these diffrent type of mathematical operator then solve some examples based on it..



Example 1:   Write a programme to find cos  value converting in radiun ?? 


Answer : 
                                #include<iostream.h>
                                #include<conio.h>
                                Void main () 
                                {
                                Clrscr() ;
                                Float a, res;
                                Cout<<" Enter value for a ";
                                Cin>>a;
                                res=cos(a*3.14/180) ;
                                Cout<<" Result is "<<res;
                                getch() ;
                                }



πŸ‘‰Output:-    


   Input :- Enter value for a 2

   Output:-    0.999391



Endl


 Endl stands for end of the line it is a manipulator function used to insert a new line character. 


#include<iostream.h>
#include<conio.h>
Void main () 
{
Clrscr() ;
Cout<<" I like computer "<<endl;
Cout<<" It is best subject "<<endl;
Cout<<" Learn computer subject every time ";
getch() ;
}


πŸ‘‰Output


Output:-        I like computer
                     It is best subject
                    Learn computer subject every time.




Slash (\n)



   Slash (\) n stands for end of the  line it also works on as endl. 
  


#include<iostream.h>
#include<conio.h>
Void main () 
{
Clrscr() ;
Cout<<" Hello\n  hii\n  welcome to by experts\n  learn in c++ here\n Thank you ";
Getch() ;
}


πŸ‘‰Output:-



   Output:-    hello
                     hii
                     welcome to by experts
                     learn in c++ here
                     Thank you. 


Slash(\) t



 It is stands for tab character. 



#include<iostream.h>
#include<conio.h>
Void main() 
{
Clrscr() ;
Cout<<"hello\t  hii\t welcome you by experts\t  learn in c++ here \t Thank you ":
Getch () ;
}



πŸ‘‰Output:-   

                  
    Output:-       hello     hii     welcome to by experts     learn in c++ here     Thank you. 




Slash (\) b:- 


It is stands for backspace character . It takes the cursor one character backward. So that when you will type next thing the character ahead of cursor will be Overwritten. 



#include<iostream.h>
#include<conio.h>
Void main ()
{
Clrscr() ;
Cout<<"hello\b hii ";
Getch () ;
}



πŸ‘‰Output:-


    Output:-     hellhii




Slash (\) r:-



 slash (\) r stands for carriage  return. It simply moves the coursor to the starting of the current line. 


#include<iostream.h>
#include<conio.h>
Void main () 
{
Clrscr() ;
Cout<<" Jharkhand\r experts ";
Getch() ;
}


πŸ‘‰Output:-


Output:-   Expertskhand





Note:-    

These all are called special formatting  character. 



                                                                                                         Manupulation Operators 




Set w:-

 Set w stands for set width we can set width  of any display. 


#include<iostream.h>
#include<conio.h>
#include<iomanip.h>
Void main ()
{
Clrscr() ;
Cout<<"set w (40) <<"Jharkhand ";
getch() ;
}
 

πŸ‘‰Output:-                              


Output:-      Jharkhand             

    



Note:-


Set w is the manipulator  oprator..


Our website: 


  πŸ˜‡ https://codemasternisha.blogspot.com/πŸ˜‡


Importants concept about C++ Programming...


πŸ‘‰  IF you want to know how to display any string or anything in C++ then   CLICK HERE
 
       πŸ‘‰ IF you want to know How to solve Complex type of mathematical Problem in C++ 

               Programming  CLICK HERE

   πŸ‘‰ IF you want to know How to calculate percentage  in C++ Programming  CLICK HERE

             

if you face any any problem or any issue about our website then fill the contact us page and write your issues in it ...

πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡πŸ‘‡



                      KEEP SUPPORTING πŸ‘Œ !!  KEEP LEARNING πŸ“š !!



                                                                    πŸ˜‡πŸ˜‡πŸ˜‡πŸ˜‡πŸ˜‡πŸ˜‡πŸ˜‡