/[LeafOK_CVS]/lbbs/src/test_bbs.c
ViewVC logotype

Contents of /lbbs/src/test_bbs.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations)
Fri Oct 24 00:47:42 2025 UTC (4 months, 3 weeks ago) by sysadm
Branch: MAIN
Changes since 1.1: +3 -1 lines
Content type: text/x-csrc
Refine

1 /***************************************************************************
2 test_bbs.c - description
3 -------------------
4 Copyright : (C) 2004-2025 by Leaflet
5 Email : leaflet@leafok.com
6 ***************************************************************************/
7
8 /***************************************************************************
9 * *
10 * This program is free software; you can redistribute it and/or modify *
11 * it under the terms of the GNU General Public License as published by *
12 * the Free Software Foundation; either version 3 of the License, or *
13 * (at your option) any later version. *
14 * *
15 ***************************************************************************/
16
17 #include "bbs.h"
18 #include <stdio.h>
19
20 int main(int argc, char *argv[])
21 {
22 int i;
23 int user_level;
24
25 const int user_points[] = {
26 -50, -1, 0, 1, 49, 50, 51, 499, 500, 501, 99999, 100000, 100001};
27
28 const int user_cnt = sizeof(user_points) / sizeof(int);
29
30 for (i = 0; i < user_cnt; i++)
31 {
32 user_level = get_user_level(user_points[i]);
33 printf("%10d\t%d\t%s\n", user_points[i], user_level, get_user_level_name(user_level));
34 }
35
36 return 0;
37 }

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1