source: proiecte/swift/trunk/test/qsort_gen.c @ 176

Last change on this file since 176 was 176, checked in by (none), 14 years ago
  • imported repo from "guagal"
File size: 437 bytes
Line 
1/*
2 * swift_context.c
3 *
4 * (c) 2009 Ionut Rosoiu <ionut.rosoiu@gmail.com>
5 *
6 */
7
8#include <stdlib.h>
9#include <stdio.h>
10
11extern void write_array(char *filename, int N);
12
13int main(int argc, char **argv) {
14        int n;
15
16        if (argc != 3) {
17                fprintf(stderr, "usage: %s <input_file> <N>\n", argv[0]);
18                abort();
19        }
20
21        n = strtol(argv[2], NULL, 10);
22        write_array(argv[1], n);
23
24        printf("wrote file %s with %d numbers\n", argv[1], n);
25
26        return 0;
27}
Note: See TracBrowser for help on using the repository browser.