File: arraydef.c

package info (click to toggle)
libffi-c-perl 0.15-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 484 kB
  • sloc: perl: 1,517; ansic: 57; sh: 19; makefile: 2
file content (14 lines) | stat: -rw-r--r-- 189 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <stdio.h>

typedef struct {
  double x, y;
} point_t;

void
print_rectangle(point_t rec[2])
{
  printf("[[%g %g] [%g %g]]\n",
    rec[0].x, rec[0].y,
    rec[1].x, rec[1].y
  );
}