Main Menu

HOME

.Net
ASP
Assembly
C
C++
Delphi
HTML
Java
JavaScript Site
MySQL
PC interface
Powershell
Perl
PHP
VBScript
Visual Basic
XML

US Job listings




   Misc

   Amazon

   Links

    


Integer division
 

 

Description

This shows integer division using the div function . The div function returns a structure called div_t , this contains the quotient and the remainder .

Code

#include <stdio.h>
#include <stdlib.h>

int main()
{

div_t result;
result = div(77,5);
printf("77 divided by 5 is %d with a remainder of %d.\n", result.quot,result.rem);
return 0;
}

Information

tested using LCC Win 32

 

 

 

 

Download

div.txt


 




   Sponsors
 

   Software
500 Java Tips E-book
PHP editor
PERL editor
Beginning Java
Beginning Visual Basic
Learn VB.net
Learn VB 6
VB and databases
ASP image library
C++ builder programming
C++ fundamentals

   Source Code
number of log file entries of a certain status code(VBScript)
deletes a folder(VB)
Simple email sender(PHP)
What type of image(PHP)
View contents of your inbox(ASP)
start excel(Powershell)
Change wallpaper(VB)
Check if a file exists(VBScript)

    




Copyright © 2003 by programmershelp.co.uk