Sign in
fuchsia
/
third_party
/
swig
/
15ace2806683e2e023160b08dd9c7ca54e8083ce
/
.
/
Examples
/
tcl
/
pointer
/
example.c
blob: b877d9a5bfc140094563ab9572026f931dadbdea [
file
] [
log
] [
blame
]
/* File : example.c */
void
add
(
int
*
x
,
int
*
y
,
int
*
result
)
{
*
result
=
*
x
+
*
y
;
}
void
sub
(
int
*
x
,
int
*
y
,
int
*
result
)
{
*
result
=
*
x
-
*
y
;
}
int
divide
(
int
n
,
int
d
,
int
*
r
)
{
int
q
;
q
=
n
/
d
;
*
r
=
n
-
q
*
d
;
return
q
;
}