Bug 7327

Summary: -isystem and template linkage
Product: gcc Reporter: hoel
Component: targetAssignee: Not yet assigned to anyone <unassigned>
Status: RESOLVED DUPLICATE    
Severity: normal CC: abrahams, austern, bhines, gcc-bugs, hoel, numien, patrick.frants
Priority: P3 Keywords: rejects-valid
Version: 3.1   
Target Milestone: ---   
Host: Target: powerpc-apple-darwin
Build: Known to work:
Known to fail: Last reconfirmed: 2004-03-06 05:05:47

Description hoel 2002-07-16 06:46:02 UTC
preparing the code snippet

#include <boost/any.hpp>

int main(void) {
  return 0;
}

with the command

g++ -save-temps -isystem /usr/software/fitools-any-any/sol2/boost
err.cxx -o err

gives almost the same preprocessed file as unsing

g++ -save-temps -I/usr/software/fitools-any-any/sol2/boost err.cxx -o
err

The only differences are of the kind where lines are

# 1 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 1 3 4

in the one .ii file against

# 1 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 1

in the other. But using -I compilation suceedes, while using -isystem I
get lots of

template with C linkage

errors.

Release:
3.1

Environment:
System: SunOS saale 5.7 Generic_106541-15 sun4u sparc SUNW,Ultra-4
Architecture: sun4


host: sparc-sun-solaris2.7
build: sparc-sun-solaris2.7
target: sparc-sun-solaris2.7
configured with: ../configure --prefix=/usr/local/fitools
--exec-prefix=/usr/local/fitools/sol2

How-To-Repeat:
just check

g++ err.ii -o erra

against

g++ errb.ii -o errb

with the attached files err.ii and errb.ii

files are:

------ start err.ii  -------
# 1 "err.cxx"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "err.cxx"
# 1 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 1 3 4
# 11 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 3 4
# 1 "/usr/local/fitools/include/g++-v3/algorithm" 1 3 4
# 65 "/usr/local/fitools/include/g++-v3/algorithm" 3

# 1 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++config.h
" 1 3
# 34
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++config.h
" 3
# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/os_defines.
h" 1 3
# 35
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++config.h
" 2 3
# 65 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/cstring" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cstring" 3

# 1 "/usr/local/fitools/include/g++-v3/cstddef" 1 3
# 47 "/usr/local/fitools/include/g++-v3/cstddef" 3

# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 1 3 4
# 147
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 3 4
typedef int ptrdiff_t;
# 201
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 3 4
typedef unsigned int size_t;
# 49 "/usr/local/fitools/include/g++-v3/cstddef" 2 3

namespace std
{
  using ::ptrdiff_t;
  using ::size_t;
}
# 50 "/usr/local/fitools/include/g++-v3/cstring" 2 3

# 1 "/usr/include/string.h" 1 3 4
# 16 "/usr/include/string.h" 3 4
#pragma ident "@(#)string.h	1.22	97/12/22 SMI"

# 1 "/usr/include/sys/feature_tests.h" 1 3 4
# 13 "/usr/include/sys/feature_tests.h" 3 4
#pragma ident "@(#)feature_tests.h	1.17	97/12/04 SMI"

# 1 "/usr/include/sys/isa_defs.h" 1 3 4
# 9 "/usr/include/sys/isa_defs.h" 3 4
#pragma ident "@(#)isa_defs.h	1.16	99/05/25 SMI"
# 148 "/usr/include/sys/isa_defs.h" 3 4
extern "C" {
# 330 "/usr/include/sys/isa_defs.h" 3 4
}
# 16 "/usr/include/sys/feature_tests.h" 2 3 4


extern "C" {
# 175 "/usr/include/sys/feature_tests.h" 3 4
}
# 19 "/usr/include/string.h" 2 3 4


extern "C" {
# 43 "/usr/include/string.h" 3 4
extern void *memcpy(void *, const void *, size_t);
extern void *memmove(void *, const void *, size_t);
extern char *strcpy(char *, const char *);
extern char *strncpy(char *, const char *, size_t);

extern char *strcat(char *, const char *);
extern char *strncat(char *, const char *, size_t);

extern int memcmp(const void *, const void *, size_t);
extern int strcmp(const char *, const char *);
extern int strcoll(const char *, const char *);
extern int strncmp(const char *, const char *, size_t);
extern size_t strxfrm(char *, const char *, size_t);

extern void *memchr(const void *, int, size_t);
extern char *strchr(const char *, int);
extern size_t strcspn(const char *, const char *);
extern char *strpbrk(const char *, const char *);
extern char *strrchr(const char *, int);
extern size_t strspn(const char *, const char *);
extern char *strstr(const char *, const char *);
extern char *strtok(char *, const char *);


extern char *strtok_r(char *, const char *, char **);

extern void *memset(void *, int, size_t);
extern char *strerror(int);
extern size_t strlen(const char *);



extern void *memccpy(void *, const void *, int, size_t);




extern char *strsignal(int);
extern int ffs(int);
extern int strcasecmp(const char *, const char *);
extern int strncasecmp(const char *, const char *, size_t);





extern char *strdup(const char *);
# 146 "/usr/include/string.h" 3 4
}
# 52 "/usr/local/fitools/include/g++-v3/cstring" 2 3
# 77 "/usr/local/fitools/include/g++-v3/cstring" 3
namespace std
{
  using ::memcpy;
  using ::memmove;
  using ::strcpy;
  using ::strncpy;
  using ::strcat;
  using ::strncat;
  using ::memcmp;
  using ::strcmp;
  using ::strcoll;
  using ::strncmp;
  using ::strxfrm;
  using ::strcspn;
  using ::strspn;
  using ::strtok;
  using ::memset;
  using ::strerror;
  using ::strlen;

  using ::memchr;

  inline void*
  memchr(void* __p, int __c, size_t __n)
  { return memchr(const_cast<const void*>(__p), __c, __n); }

  using ::strchr;

  inline char*
  strchr(char* __s1, int __n)
  { return __builtin_strchr(const_cast<const char*>(__s1), __n); }

  using ::strpbrk;

  inline char*
  strpbrk(char* __s1, const char* __s2)
  { return __builtin_strpbrk(const_cast<const char*>(__s1), __s2); }

  using ::strrchr;

  inline char*
  strrchr(char* __s1, int __n)
  { return __builtin_strrchr(const_cast<const char*>(__s1), __n); }

  using ::strstr;

  inline char*
  strstr(char* __s1, const char* __s2)
  { return __builtin_strstr(const_cast<const char*>(__s1), __s2); }
}
# 66 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/climits" 1 3
# 48 "/usr/local/fitools/include/g++-v3/climits" 3

# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 1 3 4
# 11
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
#pragma ident "@(#)limits.h	1.48	98/07/20 SMI"
# 40
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
# 1 "/usr/include/sys/int_limits.h" 1 3 4
# 9 "/usr/include/sys/int_limits.h" 3 4
#pragma ident "@(#)int_limits.h	1.5	98/01/06 SMI"
# 47 "/usr/include/sys/int_limits.h" 3 4
extern "C" {
# 162 "/usr/include/sys/int_limits.h" 3 4
}
# 41
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 2 3 4



extern "C" {
# 282
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
typedef long clock_t;


extern long _sysconf(int);
# 307
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
# 1 "/usr/include/sys/unistd.h" 1 3 4
# 25 "/usr/include/sys/unistd.h" 3 4
#pragma ident "@(#)unistd.h	1.36	98/07/16 SMI"




extern "C" {
# 264 "/usr/include/sys/unistd.h" 3 4
}
# 308
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 2 3 4
# 318
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
extern long _sysconf(int);
# 328
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
}
# 12
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 2 3 4
# 50 "/usr/local/fitools/include/g++-v3/climits" 2 3
# 67 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/cstdlib" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cstdlib" 3




# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
#pragma ident "@(#)stdlib.h	1.44	98/01/22 SMI"





# 1 "/usr/include/sys/wait.h" 1 3 4
# 16 "/usr/include/sys/wait.h" 3 4
#pragma ident "@(#)wait.h	1.21	97/04/08 SMI"



# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
#pragma ident "@(#)types.h	1.63	98/04/28 SMI"







# 1 "/usr/include/sys/machtypes.h" 1 3 4
# 16 "/usr/include/sys/machtypes.h" 3 4
#pragma ident "@(#)machtypes.h	1.12	96/08/01 SMI"




extern "C" {
# 33 "/usr/include/sys/machtypes.h" 3 4
typedef struct _physadr_t { int r[1]; } *physadr_t;

typedef struct _label_t { long val[2]; } label_t;



typedef unsigned char lock_t;


}
# 34
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 2 3 4
# 45
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
# 1 "/usr/include/sys/int_types.h" 1 3 4
# 9 "/usr/include/sys/int_types.h" 3 4
#pragma ident "@(#)int_types.h	1.6	97/08/20 SMI"
# 45 "/usr/include/sys/int_types.h" 3 4
extern "C" {
# 62 "/usr/include/sys/int_types.h" 3 4
typedef char int8_t;





typedef short int16_t;
typedef int int32_t;




typedef long long int64_t;



typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;




typedef unsigned long long uint64_t;
# 94 "/usr/include/sys/int_types.h" 3 4
typedef int64_t intmax_t;
typedef uint64_t uintmax_t;
# 110 "/usr/include/sys/int_types.h" 3 4
typedef int intptr_t;
typedef unsigned int uintptr_t;







typedef char int_least8_t;





typedef short int_least16_t;
typedef int int_least32_t;




typedef long long int_least64_t;



typedef unsigned char uint_least8_t;
typedef unsigned short uint_least16_t;
typedef unsigned int uint_least32_t;




typedef unsigned long long uint_least64_t;




}
# 46
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 2 3 4







extern "C" {
# 62
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long long longlong_t;
typedef unsigned long long u_longlong_t;
# 85
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long t_scalar_t;
typedef unsigned long t_uscalar_t;





typedef unsigned char uchar_t;
typedef unsigned short ushort_t;
typedef unsigned int uint_t;
typedef unsigned long ulong_t;

typedef char *caddr_t;
typedef long daddr_t;
typedef short cnt_t;


typedef ulong_t paddr_t;
# 125
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef ulong_t pfn_t;
typedef ulong_t pgcnt_t;
typedef long spgcnt_t;

typedef uchar_t use_t;
typedef short sysid_t;
typedef short index_t;
typedef void *timeout_id_t;
typedef void *bufcall_id_t;
# 147
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long off_t;
# 156
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef longlong_t off64_t;






typedef ulong_t ino_t;
typedef long blkcnt_t;
typedef ulong_t fsblkcnt_t;
typedef ulong_t fsfilcnt_t;
# 181
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef u_longlong_t ino64_t;
typedef longlong_t blkcnt64_t;
typedef u_longlong_t fsblkcnt64_t;
typedef u_longlong_t fsfilcnt64_t;






typedef long blksize_t;



typedef enum { _B_FALSE, _B_TRUE } boolean_t;
# 208
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef int64_t pad64_t;
typedef uint64_t upad64_t;
# 221
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef longlong_t offset_t;
typedef u_longlong_t u_offset_t;
typedef u_longlong_t len_t;
typedef longlong_t diskaddr_t;
# 242
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef union {
        offset_t _f;
        struct {
                int32_t _u;
                int32_t _l;
        } _p;
} lloff_t;
# 262
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef union {
        diskaddr_t _f;
        struct {
                int32_t _u;
                int32_t _l;
        } _p;
} lldaddr_t;


typedef uint_t k_fltset_t;
# 287
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long id_t;






typedef uint_t useconds_t;



typedef long suseconds_t;
# 308
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef ulong_t major_t;
typedef ulong_t minor_t;





typedef short pri_t;
# 328
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef ushort_t o_mode_t;
typedef short o_dev_t;
typedef ushort_t o_uid_t;
typedef o_uid_t o_gid_t;
typedef short o_nlink_t;
typedef short o_pid_t;
typedef ushort_t o_ino_t;





typedef int key_t;



typedef ulong_t mode_t;







typedef long uid_t;



typedef uid_t gid_t;






typedef unsigned int pthread_t;
typedef unsigned int pthread_key_t;

typedef struct _pthread_mutex {
        struct {
                uint8_t __pthread_mutex_flag[4];
                uint32_t __pthread_mutex_type;
        } __pthread_mutex_flags;
        union {
                struct {
                        uint8_t __pthread_mutex_pad[8];
                } __pthread_mutex_lock64;
                upad64_t __pthread_mutex_owner64;
        } __pthread_mutex_lock;
        upad64_t __pthread_mutex_data;
} pthread_mutex_t;

typedef struct _pthread_cond {
        struct {
                uint8_t __pthread_cond_flag[4];
                uint32_t __pthread_cond_type;
        } __pthread_cond_flags;
        upad64_t __pthread_cond_data;
} pthread_cond_t;




typedef struct _pthread_rwlock {
        int32_t __pthread_rwlock_readers;
        uint16_t __pthread_rwlock_type;
        uint16_t __pthread_rwlock_magic;
        upad64_t __pthread_rwlock_pad1[3];
        upad64_t __pthread_rwlock_pad2[2];
        upad64_t __pthread_rwlock_pad3[2];
} pthread_rwlock_t;




typedef struct _pthread_attr {
        void *__pthread_attrp;
} pthread_attr_t;





typedef struct _pthread_mutexattr {
        void *__pthread_mutexattrp;
} pthread_mutexattr_t;





typedef struct _pthread_condattr {
        void *__pthread_condattrp;
} pthread_condattr_t;




typedef struct _once {
        upad64_t __pthread_once_pad[4];
} pthread_once_t;





typedef struct _pthread_rwlockattr {
        void *__pthread_rwlockattrp;
} pthread_rwlockattr_t;

typedef ulong_t dev_t;





typedef ulong_t nlink_t;
typedef long pid_t;
# 470
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef int ssize_t;





typedef long time_t;
# 486
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef int clockid_t;




typedef int timer_t;






typedef unsigned char unchar;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef unsigned long ulong;
# 552
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
typedef struct _quad { int val[2]; } quad_t;
typedef quad_t quad;






# 1 "/usr/include/sys/select.h" 1 3 4
# 12 "/usr/include/sys/select.h" 3 4
#pragma ident "@(#)select.h	1.16	98/04/27 SMI"




# 1 "/usr/include/sys/time.h" 1 3 4
# 22 "/usr/include/sys/time.h" 3 4
#pragma ident "@(#)time.h	2.62	98/02/04 SMI"
# 32 "/usr/include/sys/time.h" 3 4
extern "C" {
# 49 "/usr/include/sys/time.h" 3 4
struct timeval {
        time_t tv_sec;
        suseconds_t tv_usec;
};
# 82 "/usr/include/sys/time.h" 3 4
struct timezone {
        int tz_minuteswest;
        int tz_dsttime;
};





}
# 100 "/usr/include/sys/time.h" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 1 3 4
# 101 "/usr/include/sys/time.h" 2 3 4



extern "C" {
# 155 "/usr/include/sys/time.h" 3 4
struct itimerval {
        struct timeval it_interval;
        struct timeval it_value;
};
# 203 "/usr/include/sys/time.h" 3 4
typedef longlong_t hrtime_t;
# 315 "/usr/include/sys/time.h" 3 4
int adjtime(struct timeval *, struct timeval *);
# 326 "/usr/include/sys/time.h" 3 4
int getitimer(int, struct itimerval *);
int utimes(const char *, const struct timeval *);

int setitimer(int, const struct itimerval *, struct itimerval *);
# 364 "/usr/include/sys/time.h" 3 4
int settimeofday(struct timeval *, void *);

hrtime_t gethrtime(void);
hrtime_t gethrvtime(void);
# 384 "/usr/include/sys/time.h" 3 4
int gettimeofday(struct timeval *, void *);
# 405 "/usr/include/sys/time.h" 3 4
# 1 "/usr/include/time.h" 1 3 4
# 16 "/usr/include/time.h" 3 4
#pragma ident "@(#)time.h	1.36	98/03/27 SMI"





extern "C" {
# 64 "/usr/include/time.h" 3 4
struct tm {
        int tm_sec;
        int tm_min;
        int tm_hour;
        int tm_mday;
        int tm_mon;
        int tm_year;
        int tm_wday;
        int tm_yday;
        int tm_isdst;
};



extern clock_t clock(void);
extern double difftime(time_t, time_t);
extern time_t mktime(struct tm *);
extern time_t time(time_t *);
extern char *asctime(const struct tm *);
extern char *ctime(const time_t *);
extern struct tm *gmtime(const time_t *);
extern struct tm *localtime(const time_t *);
extern size_t strftime(char *, size_t, const char *, const struct tm *);



extern struct tm *gmtime_r(const time_t *, struct tm *);
extern struct tm *localtime_r(const time_t *, struct tm *);





extern char *strptime(const char *, const char *, struct tm *);





# 1 "/usr/include/sys/time_impl.h" 1 3 4
# 15 "/usr/include/sys/time_impl.h" 3 4
#pragma ident "@(#)time_impl.h	1.3	98/02/13 SMI"




extern "C" {
# 36 "/usr/include/sys/time_impl.h" 3 4
typedef struct timespec {
        time_t tv_sec;
        long tv_nsec;
} timespec_t;
# 60 "/usr/include/sys/time_impl.h" 3 4
typedef struct timespec timestruc_t;
# 79 "/usr/include/sys/time_impl.h" 3 4
typedef struct itimerspec {
        struct timespec it_interval;
        struct timespec it_value;
} itimerspec_t;
# 130 "/usr/include/sys/time_impl.h" 3 4
}
# 104 "/usr/include/time.h" 2 3 4
# 118 "/usr/include/time.h" 3 4
union sigval {
        int sival_int;
        void *sival_ptr;
};




struct sigevent {
        int sigev_notify;
        int sigev_signo;
        union sigval sigev_value;
        void (*sigev_notify_function)(union sigval);
        pthread_attr_t *sigev_notify_attributes;
        int __sigev_pad2;
};


extern int clock_getres(clockid_t, struct timespec *);
extern int clock_gettime(clockid_t, struct timespec *);
extern int clock_settime(clockid_t, const struct timespec *);
extern int timer_create(clockid_t, struct sigevent *, timer_t *);
extern int timer_delete(timer_t);
extern int timer_getoverrun(timer_t);
extern int timer_gettime(timer_t, struct itimerspec *);
extern int timer_settime(timer_t, int, const struct itimerspec *,
                struct itimerspec *);
extern int nanosleep(const struct timespec *, struct timespec *);




extern void tzset(void);

extern char *tzname[2];
# 162 "/usr/include/time.h" 3 4
extern long timezone;
extern int daylight;
# 176 "/usr/include/time.h" 3 4
extern struct tm *getdate(const char *);






extern int getdate_err;
# 266 "/usr/include/time.h" 3 4
extern char *asctime_r(const struct tm *, char *);
extern char *ctime_r(const time_t *, char *);
#pragma redefine_extname ctime_r __posix_ctime_r
#pragma redefine_extname asctime_r __posix_asctime_r
# 334 "/usr/include/time.h" 3 4
}
# 406 "/usr/include/sys/time.h" 2 3 4
# 418 "/usr/include/sys/time.h" 3 4
# 1 "/usr/include/sys/select.h" 1 3 4
# 419 "/usr/include/sys/time.h" 2 3 4





}
# 18 "/usr/include/sys/select.h" 2 3 4



extern "C" {
# 45 "/usr/include/sys/select.h" 3 4
typedef long fd_mask;

typedef long fds_mask;
# 73 "/usr/include/sys/select.h" 3 4
typedef struct fd_set {



        long fds_bits[(((1024)+(((sizeof (fds_mask) * 8))-1))/((sizeof
(fds_mask) * 8)))];
} fd_set;
# 97 "/usr/include/sys/select.h" 3 4
extern int select(int, fd_set *, fd_set *, fd_set *, struct timeval *);






}
# 565
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 2 3 4
# 581
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
}
# 21 "/usr/include/sys/wait.h" 2 3 4



# 1 "/usr/include/sys/resource.h" 1 3 4
# 16 "/usr/include/sys/resource.h" 3 4
#pragma ident "@(#)resource.h	1.25	98/06/30 SMI"







extern "C" {
# 67 "/usr/include/sys/resource.h" 3 4
typedef unsigned long rlim_t;
# 102 "/usr/include/sys/resource.h" 3 4
struct rlimit {
        rlim_t rlim_cur;
        rlim_t rlim_max;
};




typedef u_longlong_t rlim64_t;





struct rlimit64 {
        rlim64_t rlim_cur;
        rlim64_t rlim_max;
};
# 143 "/usr/include/sys/resource.h" 3 4
struct rusage {
        struct timeval ru_utime;
        struct timeval ru_stime;
        long ru_maxrss;
        long ru_ixrss;
        long ru_idrss;
        long ru_isrss;
        long ru_minflt;
        long ru_majflt;
        long ru_nswap;
        long ru_inblock;
        long ru_oublock;
        long ru_msgsnd;
        long ru_msgrcv;
        long ru_nsignals;
        long ru_nvcsw;
        long ru_nivcsw;
};
# 193 "/usr/include/sys/resource.h" 3 4
extern int setrlimit(int, const struct rlimit *);
extern int getrlimit(int, struct rlimit *);




extern int setrlimit64(int, const struct rlimit64 *);
extern int getrlimit64(int, struct rlimit64 *);


extern int getpriority(int, id_t);
extern int setpriority(int, id_t, int);
extern int getrusage(int, struct rusage *);
# 228 "/usr/include/sys/resource.h" 3 4
}
# 25 "/usr/include/sys/wait.h" 2 3 4
# 1 "/usr/include/sys/siginfo.h" 1 3 4
# 16 "/usr/include/sys/siginfo.h" 3 4
#pragma ident "@(#)siginfo.h	1.54	98/03/27 SMI"





extern "C" {
# 126 "/usr/include/sys/siginfo.h" 3 4
# 1 "/usr/include/sys/machsig.h" 1 3 4
# 16 "/usr/include/sys/machsig.h" 3 4
#pragma ident "@(#)machsig.h	1.14	98/02/05 SMI"





extern "C" {
# 110 "/usr/include/sys/machsig.h" 3 4
}
# 127 "/usr/include/sys/siginfo.h" 2 3 4
# 221 "/usr/include/sys/siginfo.h" 3 4
typedef struct siginfo {



        int si_signo;
        int si_code;
        int si_errno;



        union {

                int __pad[((128 / sizeof (int)) - 3)];

                struct {
                        pid_t __pid;
                        union {
                                struct {
                                        uid_t __uid;


                                        union sigval __value;



                                } __kill;
                                struct {
                                        clock_t __utime;
                                        int __status;
                                        clock_t __stime;
                                } __cld;
                        } __pdata;
                } __proc;

                struct {
                        void *__addr;
                        int __trapno;
                        caddr_t __pc;
                } __fault;

                struct {

                        int __fd;
                        long __band;
                } __file;

                struct {
                        caddr_t __faddr;


                        timestruc_t __tstamp;



                        short __syscall;
                        char __nsysarg;
                        char __fault;
                        long __sysarg[8];
                        int __mstate[10];
                } __prof;

        } __data;

} siginfo_t;
# 354 "/usr/include/sys/siginfo.h" 3 4
typedef struct k_siginfo {
        int si_signo;
        int si_code;
        int si_errno;



        union {
                struct {
                        pid_t __pid;
                        union {
                                struct {
                                        uid_t __uid;
                                        union sigval __value;
                                } __kill;
                                struct {
                                        clock_t __utime;
                                        int __status;
                                        clock_t __stime;
                                } __cld;
                        } __pdata;
                } __proc;

                struct {
                        void *__addr;
                        int __trapno;
                        caddr_t __pc;
                } __fault;

                struct {

                        int __fd;
                        long __band;
                } __file;

                struct {
                        caddr_t __faddr;



                        timestruc_t __tstamp;



                        short __syscall;
                        char __nsysarg;
                        char __fault;



                } __prof;

        } __data;

} k_siginfo_t;

typedef struct sigqueue {
        struct sigqueue *sq_next;
        k_siginfo_t sq_info;
        void (*sq_func)(struct sigqueue *);
        void *sq_backptr;

} sigqueue_t;
# 454 "/usr/include/sys/siginfo.h" 3 4
}
# 26 "/usr/include/sys/wait.h" 2 3 4
# 1 "/usr/include/sys/procset.h" 1 3 4
# 16 "/usr/include/sys/procset.h" 3 4
#pragma ident "@(#)procset.h	1.18	98/06/30 SMI"


extern "C" {
# 40 "/usr/include/sys/procset.h" 3 4
typedef enum

        idtype

                {
        P_PID,
        P_PPID,
        P_PGID,

        P_SID,
        P_CID,
        P_UID,
        P_GID,
        P_ALL,
        P_LWPID
} idtype_t;
# 64 "/usr/include/sys/procset.h" 3 4
typedef enum idop {
        POP_DIFF,


        POP_AND,


        POP_OR,


        POP_XOR


} idop_t;







typedef struct procset {
        idop_t p_op;




        idtype_t p_lidtype;


        id_t p_lid;

        idtype_t p_ridtype;


        id_t p_rid;
} procset_t;
# 129 "/usr/include/sys/procset.h" 3 4
}
# 27 "/usr/include/sys/wait.h" 2 3 4



extern "C" {
# 86 "/usr/include/sys/wait.h" 3 4
extern pid_t wait(int *);
extern pid_t waitpid(pid_t, int *, int);


extern int waitid(idtype_t, id_t, siginfo_t *, int);
extern pid_t wait3(int *, int, struct rusage *);




extern pid_t wait4(pid_t, int *, int, struct rusage *);
# 118 "/usr/include/sys/wait.h" 3 4
}
# 32
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 2 3 4



extern "C" {


typedef struct {
        int quot;
        int rem;
} div_t;

typedef struct {
        long quot;
        long rem;
} ldiv_t;


typedef struct {
        long long quot;
        long long rem;
} lldiv_t;
# 148
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
extern unsigned char __ctype[];



extern double atof(const char *);
extern int atoi(const char *);
extern long int atol(const char *);
extern double strtod(const char *, char **);
extern long int strtol(const char *, char **, int);
extern unsigned long int strtoul(const char *, char **, int);

extern int rand(void);
extern void srand(unsigned int);


extern int rand_r(unsigned int *);


extern void *calloc(size_t, size_t);
extern void free(void *);
extern void *malloc(size_t);
extern void *realloc(void *, size_t);

extern void abort(void);
extern int atexit(void (*)(void));
extern void exit(int);
extern void _exithandle(void);
extern char *getenv(const char *);
extern int system(const char *);

extern void *bsearch(const void *, const void *, size_t, size_t,
        int (*)(const void *, const void *));
extern void qsort(void *, size_t, size_t,
        int (*)(const void *, const void *));

extern int abs(int);
extern div_t div(int, int);
extern long int labs(long);
extern ldiv_t ldiv(long, long);

extern int mbtowc(wchar_t *, const char *, size_t);
extern int mblen(const char *, size_t);
extern int wctomb(char *, wchar_t);

extern size_t mbstowcs(wchar_t *, const char *, size_t);
extern size_t wcstombs(char *, const wchar_t *, size_t);




extern double drand48(void);
extern double erand48(unsigned short *);
extern long jrand48(unsigned short *);
extern void lcong48(unsigned short *);
extern long lrand48(void);
extern long mrand48(void);
extern long nrand48(unsigned short *);
extern unsigned short *seed48(unsigned short *);
extern void srand48(long);
extern int putenv(char *);
extern void setkey(const char *);
# 219
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
extern int mkstemp(char *);


extern int mkstemp64(char *);






extern long a64l(const char *);
extern char *ecvt(double, int, int *, int *);
extern char *fcvt(double, int, int *, int *);
extern char *gcvt(double, int, char *);
extern int getsubopt(char **, char *const *, char **);
extern int grantpt(int);
extern char *initstate(unsigned, char *, size_t);
extern char *l64a(long);
extern char *mktemp(char *);
extern char *ptsname(int);
extern long random(void);
extern char *realpath(const char *, char *);
extern char *setstate(const char *);
extern void srandom(unsigned);
extern int ttyslot(void);
extern int unlockpt(int);
extern void *valloc(size_t);




extern int dup2(int, int);
extern char *qecvt(long double, int, int *, int *);
extern char *qfcvt(long double, int, int *, int *);
extern char *qgcvt(long double, int, char *);
extern char *getcwd(char *, size_t);
extern const char *getexecname(void);
extern char *getlogin(void);
extern int getopt(int, char *const *, const char *);
extern char *optarg;
extern int optind, opterr, optopt;
extern char *getpass(const char *);
extern char *getpassphrase(const char *);
extern int getpw(uid_t, char *);
extern int isatty(int);
extern void *memalign(size_t, size_t);
extern char *ttyname(int);


extern long long atoll(const char *);
extern long long llabs(long long);
extern lldiv_t lldiv(long long, long long);
extern char *lltostr(long long, char *);
extern long long strtoll(const char *, char **, int);
extern unsigned long long strtoull(const char *, char **, int);
extern char *ulltostr(unsigned long long, char *);
# 412
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
}
# 53 "/usr/local/fitools/include/g++-v3/cstdlib" 2 3
# 84 "/usr/local/fitools/include/g++-v3/cstdlib" 3
namespace std
{
  using ::div_t;
  using ::ldiv_t;

  using ::abort;
  using ::abs;
  using ::atexit;
  using ::atof;
  using ::atoi;
  using ::atol;
  using ::bsearch;
  using ::calloc;
  using ::div;
  using ::exit;
  using ::free;
  using ::getenv;
  using ::labs;
  using ::ldiv;
  using ::malloc;
  using ::mblen;
  using ::mbstowcs;
  using ::mbtowc;
  using ::qsort;
  using ::rand;
  using ::realloc;
  using ::srand;
  using ::strtod;
  using ::strtol;
  using ::strtoul;
  using ::system;
  using ::wcstombs;
  using ::wctomb;

  inline long
  abs(long __i) { return labs(__i); }

  inline ldiv_t
  div(long __i, long __j) { return ldiv(__i, __j); }
}
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3

# 1 "/usr/local/fitools/include/g++-v3/new" 1 3
# 42 "/usr/local/fitools/include/g++-v3/new" 3
# 1 "/usr/local/fitools/include/g++-v3/exception" 1 3
# 40 "/usr/local/fitools/include/g++-v3/exception" 3
extern "C++" {

namespace std
{






  class exception
  {
  public:
    exception() throw() { }
    virtual ~exception() throw();


    virtual const char* what() const throw();
  };



  class bad_exception : public exception
  {
  public:
    bad_exception() throw() { }


    virtual ~bad_exception() throw();
  };


  typedef void (*terminate_handler) ();

  typedef void (*unexpected_handler) ();


  terminate_handler set_terminate(terminate_handler) throw();


  void terminate() __attribute__ ((__noreturn__));


  unexpected_handler set_unexpected(unexpected_handler) throw();


  void unexpected() __attribute__ ((__noreturn__));
# 98 "/usr/local/fitools/include/g++-v3/exception" 3
  bool uncaught_exception() throw();
}

namespace __gnu_cxx
{
# 111 "/usr/local/fitools/include/g++-v3/exception" 3
  void __verbose_terminate_handler ();
}

}
# 43 "/usr/local/fitools/include/g++-v3/new" 2 3

extern "C++" {

namespace std
{


  class bad_alloc : public exception
  {
  public:
    bad_alloc() throw() { }


    virtual ~bad_alloc() throw();
  };

  struct nothrow_t { };
  extern const nothrow_t nothrow;


  typedef void (*new_handler)();

  new_handler set_new_handler(new_handler);
}
# 79 "/usr/local/fitools/include/g++-v3/new" 3
void* operator new(std::size_t) throw (std::bad_alloc);
void* operator new[](std::size_t) throw (std::bad_alloc);
void operator delete(void*) throw();
void operator delete[](void*) throw();
void* operator new(std::size_t, const std::nothrow_t&) throw();
void* operator new[](std::size_t, const std::nothrow_t&) throw();
void operator delete(void*, const std::nothrow_t&) throw();
void operator delete[](void*, const std::nothrow_t&) throw();


inline void* operator new(std::size_t, void* __p) throw() { return __p;
}
inline void* operator new[](std::size_t, void* __p) throw() { return
__p; }

}
# 70 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/iosfwd" 1 3
# 43 "/usr/local/fitools/include/g++-v3/iosfwd" 3


# 1 "/usr/local/fitools/include/g++-v3/bits/stringfwd.h" 1 3
# 43 "/usr/local/fitools/include/g++-v3/bits/stringfwd.h" 3



namespace std
{
  template<class _CharT>
    struct char_traits;

  template<> struct char_traits<char>;




  template<typename _Alloc>
    class allocator;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_string;

  typedef basic_string<char> string;
  typedef basic_string<wchar_t> wstring;
}
# 46 "/usr/local/fitools/include/g++-v3/iosfwd" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 1 3
# 43 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 3

# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 1
3
# 35
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 3
# 1 "/usr/local/fitools/include/g++-v3/cstdio" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cstdio" 3




# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 1 3 4
# 14
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
darg.h" 1 3 4
# 43
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
darg.h" 3 4
typedef __builtin_va_list __gnuc_va_list;
# 15
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 34
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
#pragma ident "@(#)stdio.h	1.69	98/07/13 SMI"


# 1 "/usr/include/sys/va_list.h" 1 3 4
# 9 "/usr/include/sys/va_list.h" 3 4
#pragma ident "@(#)va_list.h	1.11	97/11/22 SMI"
# 22 "/usr/include/sys/va_list.h" 3 4
extern "C" {



typedef void *__va_list;





}
# 38
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio_tag.h" 1 3 4
# 18
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio_tag.h" 3 4
#pragma ident "@(#)stdio_tag.h	1.3	98/04/20 SMI"


extern "C" {
# 30
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio_tag.h" 3 4
typedef struct __FILE __FILE;



}
# 39
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 1 "/usr/include/stdio_impl.h" 1 3 4
# 9 "/usr/include/stdio_impl.h" 3 4
#pragma ident "@(#)stdio_impl.h	1.8	99/06/30 SMI"




extern "C" {
# 38 "/usr/include/stdio_impl.h" 3 4
struct __FILE
{




        ssize_t _cnt;
        unsigned char *_ptr;

        unsigned char *_base;
        unsigned char _flag;
        unsigned char _file;
        unsigned __orientation:2;
        unsigned __ionolock:1;
        unsigned __filler:5;
};




}
# 40
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 50
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern "C" {




typedef __FILE FILE;
# 74
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
typedef long long __longlong_t;
# 103
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
typedef long fpos_t;







typedef __longlong_t fpos64_t;
# 132
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
typedef __va_list __not_va_list__;
# 203
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE __iob[20];
# 215
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern unsigned char _sibuf[], _sobuf[];
# 244
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern unsigned char *_bufendtab[];
extern FILE *_lastbuf;
# 275
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern int remove(const char *);
extern int rename(const char *, const char *);
extern FILE *tmpfile(void);
extern char *tmpnam(char *);

extern char *tmpnam_r(char *);

extern int fclose(FILE *);
extern int fflush(FILE *);
extern FILE *fopen(const char *, const char *);
extern FILE *freopen(const char *, const char *, FILE *);
extern void setbuf(FILE *, char *);


extern void setbuffer(FILE *, char *, size_t);
extern int setlinebuf(FILE *);

extern int setvbuf(FILE *, char *, int, size_t);

extern int fprintf(FILE *, const char *, ...);

extern int fscanf(FILE *, const char *, ...);

extern int printf(const char *, ...);

extern int scanf(const char *, ...);




extern int snprintf(char *, size_t, const char *, ...);


extern int sprintf(char *, const char *, ...);

extern int sscanf(const char *, const char *, ...);
extern int vfprintf(FILE *, const char *, __gnuc_va_list);
extern int vprintf(const char *, __gnuc_va_list);



extern int vsnprintf(char *, size_t, const char *, __gnuc_va_list);

extern int vsprintf(char *, const char *, __gnuc_va_list);
extern int fgetc(FILE *);
extern char *fgets(char *, int, FILE *);
extern int fputc(int, FILE *);
extern int fputs(const char *, FILE *);
extern int getc(FILE *);
extern int getchar(void);
extern char *gets(char *);
extern int putc(int, FILE *);
extern int putchar(int);
extern int puts(const char *);
extern int ungetc(int, FILE *);
extern size_t fread(void *, size_t, size_t, FILE *);
extern size_t fwrite(const void *, size_t, size_t, FILE *);
extern int fgetpos(FILE *, fpos_t *);
extern int fseek(FILE *, long, int);
extern int fsetpos(FILE *, const fpos_t *);
extern long ftell(FILE *);
extern void rewind(FILE *);
extern void clearerr(FILE *);
extern int feof(FILE *);
extern int ferror(FILE *);
extern void perror(const char *);


extern int __filbuf(FILE *);
extern int __flsbuf(int, FILE *);
# 353
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE *fdopen(int, const char *);
extern char *ctermid(char *);
extern int fileno(FILE *);
# 364
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern void flockfile(FILE *);
extern int ftrylockfile(FILE *);
extern void funlockfile(FILE *);
extern int getc_unlocked(FILE *);
extern int getchar_unlocked(void);
extern int putc_unlocked(int, FILE *);
extern int putchar_unlocked(int);
# 379
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE *popen(const char *, const char *);
extern char *cuserid(char *);
extern char *tempnam(const char *, const char *);
extern int getopt(int, char *const *, const char *);



extern char *optarg;
extern int optind, opterr, optopt;
extern int getw(FILE *);
extern int putw(int, FILE *);
extern int pclose(FILE *);







extern int fseeko(FILE *, off_t, int);
extern off_t ftello(FILE *);
# 408
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE *fopen64(const char *, const char *);
extern FILE *freopen64(const char *, const char *, FILE *);
extern FILE *tmpfile64(void);
extern int fgetpos64(FILE *, fpos64_t *);
extern int fsetpos64(FILE *, const fpos64_t *);
extern int fseeko64(FILE *, off64_t, int);
extern off64_t ftello64(FILE *);
# 586
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
}
# 53 "/usr/local/fitools/include/g++-v3/cstdio" 2 3
# 97 "/usr/local/fitools/include/g++-v3/cstdio" 3
namespace std
{
  using ::FILE;
  using ::fpos_t;

  using ::clearerr;
  using ::fclose;
  using ::feof;
  using ::ferror;
  using ::fflush;
  using ::fgetc;
  using ::fgetpos;
  using ::fgets;
  using ::fopen;
  using ::fprintf;
  using ::fputc;
  using ::fputs;
  using ::fread;
  using ::freopen;
  using ::fscanf;
  using ::fseek;
  using ::fsetpos;
  using ::ftell;
  using ::fwrite;
  using ::getc;
  using ::getchar;
  using ::gets;
  using ::perror;
  using ::printf;
  using ::putc;
  using ::putchar;
  using ::puts;
  using ::remove;
  using ::rename;
  using ::rewind;
  using ::scanf;
  using ::setbuf;
  using ::setvbuf;
  using ::sprintf;
  using ::sscanf;
  using ::tmpfile;
  using ::tmpnam;
  using ::ungetc;
  using ::vfprintf;
  using ::vprintf;
  using ::vsprintf;
}
# 36
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 2
3

# 1 "/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr.h"
1 3
# 98
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr.h" 3
# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 1 3
# 37
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 3
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 1 3 4
# 18
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
#pragma ident "@(#)pthread.h	1.26	98/04/12 SMI"




# 1 "/usr/include/sched.h" 1 3 4
# 11 "/usr/include/sched.h" 3 4
#pragma ident "@(#)sched.h	1.9	98/01/16 SMI"





extern "C" {


struct sched_param {
        int sched_priority;
        int sched_nicelim;
        int sched_nice;
        int sched_pad[6];



};
# 44 "/usr/include/sched.h" 3 4
int sched_getparam(pid_t pid, struct sched_param *param);
int sched_setparam(pid_t pid, const struct sched_param *param);
int sched_getscheduler(pid_t pid);
int sched_setscheduler(pid_t pid, int policy,
                const struct sched_param *param);
int sched_yield(void);
int sched_get_priority_max(int policy);
int sched_get_priority_min(int policy);
int sched_rr_get_interval(pid_t pid, struct timespec *interval);
# 65 "/usr/include/sched.h" 3 4
}
# 24
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 2 3 4



extern "C" {
# 103
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
typedef struct _cleanup {
        uintptr_t pthread_cleanup_pad[4];
} _cleanup_t;



void __pthread_cleanup_push(void (*routine)(void *), void *args,
                                        caddr_t fp, _cleanup_t *info);
void __pthread_cleanup_pop(int ex, _cleanup_t *info);
caddr_t _getfp(void);
# 137
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
extern int pthread_attr_init(pthread_attr_t *);
extern int pthread_attr_destroy(pthread_attr_t *);
extern int pthread_attr_setstacksize(pthread_attr_t *, size_t);
extern int pthread_attr_getstacksize(const pthread_attr_t *, size_t *);
extern int pthread_attr_setstackaddr(pthread_attr_t *, void *);
extern int pthread_attr_getstackaddr(const pthread_attr_t *, void **);
extern int pthread_attr_setdetachstate(pthread_attr_t *, int);
extern int pthread_attr_getdetachstate(const pthread_attr_t *, int *);
extern int pthread_attr_setscope(pthread_attr_t *, int);
extern int pthread_attr_getscope(const pthread_attr_t *, int *);
extern int pthread_attr_setinheritsched(pthread_attr_t *, int);
extern int pthread_attr_getinheritsched(const pthread_attr_t *, int *);
extern int pthread_attr_setschedpolicy(pthread_attr_t *, int);
extern int pthread_attr_getschedpolicy(const pthread_attr_t *, int *);
extern int pthread_attr_setschedparam(pthread_attr_t *,
                                        const struct sched_param *);
extern int pthread_attr_getschedparam(const pthread_attr_t *,
                                        struct sched_param *);
extern int pthread_create(pthread_t *, const pthread_attr_t *,
                                void * (*)(void *), void *);
extern int pthread_once(pthread_once_t *, void (*)(void));
extern int pthread_join(pthread_t, void **);
extern int pthread_detach(pthread_t);
extern void pthread_exit(void *);
extern int pthread_cancel(pthread_t);
extern int pthread_setschedparam(pthread_t, int, const struct
sched_param *);
extern int pthread_getschedparam(pthread_t, int *, struct sched_param
*);
extern int pthread_setcancelstate(int, int *);
extern int pthread_setcanceltype(int, int *);
extern void pthread_testcancel(void);
extern int pthread_equal(pthread_t, pthread_t);
extern int pthread_key_create(pthread_key_t *, void (*)(void *));
extern int pthread_key_delete(pthread_key_t);
extern int pthread_setspecific(pthread_key_t, const void *);
extern void *pthread_getspecific(pthread_key_t);
extern pthread_t pthread_self(void);




extern int pthread_mutexattr_init(pthread_mutexattr_t *);
extern int pthread_mutexattr_destroy(pthread_mutexattr_t *);
extern int pthread_mutexattr_setpshared(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_getpshared(const pthread_mutexattr_t *, int
*);
extern int pthread_mutexattr_setprotocol(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_getprotocol(const pthread_mutexattr_t *,
int *);
extern int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_getprioceiling(const pthread_mutexattr_t *,
int *);
extern int pthread_mutex_init(pthread_mutex_t *, const
pthread_mutexattr_t *);
extern int pthread_mutex_destroy(pthread_mutex_t *);
extern int pthread_mutex_lock(pthread_mutex_t *);
extern int pthread_mutex_unlock(pthread_mutex_t *);
extern int pthread_mutex_trylock(pthread_mutex_t *);
extern int pthread_mutex_setprioceiling(pthread_mutex_t *, int, int *);
extern int pthread_mutex_getprioceiling(pthread_mutex_t *, int *);
extern int pthread_condattr_init(pthread_condattr_t *);
extern int pthread_condattr_destroy(pthread_condattr_t *);
extern int pthread_condattr_setpshared(pthread_condattr_t *, int);
extern int pthread_condattr_getpshared(const pthread_condattr_t *, int
*);
extern int pthread_cond_init(pthread_cond_t *, const pthread_condattr_t
*);
extern int pthread_cond_destroy(pthread_cond_t *);
extern int pthread_cond_broadcast(pthread_cond_t *);
extern int pthread_cond_signal(pthread_cond_t *);
extern int pthread_cond_wait(pthread_cond_t *, pthread_mutex_t *);
extern int pthread_cond_timedwait(pthread_cond_t *, pthread_mutex_t *,
                                        const struct timespec *);
extern int pthread_attr_getguardsize(const pthread_attr_t *, size_t *);
extern int pthread_attr_setguardsize(pthread_attr_t *, size_t);
extern int pthread_getconcurrency(void);
extern int pthread_setconcurrency(int newval);
extern int pthread_mutexattr_settype(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_gettype(const pthread_mutexattr_t *, int
*);
extern int pthread_rwlock_init(pthread_rwlock_t *,
                                const pthread_rwlockattr_t *);
extern int pthread_rwlock_destroy(pthread_rwlock_t *);
extern int pthread_rwlock_rdlock(pthread_rwlock_t *);
extern int pthread_rwlock_tryrdlock(pthread_rwlock_t *);
extern int pthread_rwlock_wrlock(pthread_rwlock_t *);
extern int pthread_rwlock_trywrlock(pthread_rwlock_t *);
extern int pthread_rwlock_unlock(pthread_rwlock_t *);
extern int pthread_rwlockattr_init(pthread_rwlockattr_t *);
extern int pthread_rwlockattr_destroy(pthread_rwlockattr_t *);
extern int pthread_rwlockattr_getpshared(const pthread_rwlockattr_t *,
int *);
extern int pthread_rwlockattr_setpshared(pthread_rwlockattr_t *, int);
# 312
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
}
# 38
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 2 3

typedef pthread_key_t __gthread_key_t;
typedef pthread_once_t __gthread_once_t;
typedef pthread_mutex_t __gthread_mutex_t;






#pragma weak pthread_once
#pragma weak pthread_key_create
#pragma weak pthread_key_delete
#pragma weak pthread_getspecific
#pragma weak pthread_setspecific
#pragma weak pthread_create

#pragma weak pthread_mutex_lock
#pragma weak pthread_mutex_trylock
#pragma weak pthread_mutex_unlock
# 80
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 3
static inline int
__gthread_active_p (void)
{
  static void *const __gthread_active_ptr = (void *) &pthread_create;
  return __gthread_active_ptr != 0;
}
# 437
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 3
static inline int
__gthread_once (__gthread_once_t *once, void (*func) (void))
{
  if (__gthread_active_p ())
    return pthread_once (once, func);
  else
    return -1;
}

static inline int
__gthread_key_create (__gthread_key_t *key, void (*dtor) (void *))
{
  return pthread_key_create (key, dtor);
}

static inline int
__gthread_key_dtor (__gthread_key_t key, void *ptr)
{

  if (ptr)
    return pthread_setspecific (key, 0);
  else
    return 0;
}

static inline int
__gthread_key_delete (__gthread_key_t key)
{
  return pthread_key_delete (key);
}

static inline void *
__gthread_getspecific (__gthread_key_t key)
{
  return pthread_getspecific (key);
}

static inline int
__gthread_setspecific (__gthread_key_t key, const void *ptr)
{
  return pthread_setspecific (key, ptr);
}

static inline int
__gthread_mutex_lock (__gthread_mutex_t *mutex)
{
  if (__gthread_active_p ())
    return pthread_mutex_lock (mutex);
  else
    return 0;
}

static inline int
__gthread_mutex_trylock (__gthread_mutex_t *mutex)
{
  if (__gthread_active_p ())
    return pthread_mutex_trylock (mutex);
  else
    return 0;
}

static inline int
__gthread_mutex_unlock (__gthread_mutex_t *mutex)
{
  if (__gthread_active_p ())
    return pthread_mutex_unlock (mutex);
  else
    return 0;
}
# 99
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr.h" 2 3
# 38
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 2
3

namespace std
{

  typedef long streamoff;
  typedef ptrdiff_t streamsize;



  typedef fpos_t __c_streampos;

  typedef __gthread_mutex_t __c_lock;


  typedef FILE __c_file;


  struct __ios_flags
  {
    typedef short __int_type;

    static const __int_type _S_boolalpha = 0x0001;
    static const __int_type _S_dec = 0x0002;
    static const __int_type _S_fixed = 0x0004;
    static const __int_type _S_hex = 0x0008;
    static const __int_type _S_internal = 0x0010;
    static const __int_type _S_left = 0x0020;
    static const __int_type _S_oct = 0x0040;
    static const __int_type _S_right = 0x0080;
    static const __int_type _S_scientific = 0x0100;
    static const __int_type _S_showbase = 0x0200;
    static const __int_type _S_showpoint = 0x0400;
    static const __int_type _S_showpos = 0x0800;
    static const __int_type _S_skipws = 0x1000;
    static const __int_type _S_unitbuf = 0x2000;
    static const __int_type _S_uppercase = 0x4000;
    static const __int_type _S_adjustfield = 0x0020 | 0x0080 | 0x0010;
    static const __int_type _S_basefield = 0x0002 | 0x0040 | 0x0008;
    static const __int_type _S_floatfield = 0x0100 | 0x0004;


    static const __int_type _S_badbit = 0x01;
    static const __int_type _S_eofbit = 0x02;
    static const __int_type _S_failbit = 0x04;


    static const __int_type _S_app = 0x01;
    static const __int_type _S_ate = 0x02;
    static const __int_type _S_bin = 0x04;
    static const __int_type _S_in = 0x08;
    static const __int_type _S_out = 0x10;
    static const __int_type _S_trunc = 0x20;
  };
}
# 45 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/cwchar" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cwchar" 3



# 1 "/usr/local/fitools/include/g++-v3/ctime" 1 3
# 48 "/usr/local/fitools/include/g++-v3/ctime" 3
# 64 "/usr/local/fitools/include/g++-v3/ctime" 3
namespace std
{
  using ::clock_t;
  using ::time_t;
  using ::tm;

  using ::clock;
  using ::difftime;
  using ::mktime;
  using ::time;
  using ::asctime;
  using ::ctime;
  using ::gmtime;
  using ::localtime;
  using ::strftime;
}
# 52 "/usr/local/fitools/include/g++-v3/cwchar" 2 3


# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 1 3 4
# 18
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
#pragma ident "@(#)wchar.h	1.31	98/05/04 SMI"




# 1 "/usr/include/wchar_impl.h" 1 3 4
# 9 "/usr/include/wchar_impl.h" 3 4
#pragma ident "@(#)wchar_impl.h	1.2	98/02/27 SMI"




extern "C" {



typedef struct {



        int __filler[6];

} __mbstate_t;



}
# 24
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 2 3 4
# 33
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
# 1 "/usr/include/ctype.h" 1 3 4
# 16 "/usr/include/ctype.h" 3 4
#pragma ident "@(#)ctype.h	1.30	98/01/16 SMI"




extern "C" {
# 48 "/usr/include/ctype.h" 3 4
extern int isalnum(int);
extern int isalpha(int);
extern int iscntrl(int);
extern int isdigit(int);
extern int isgraph(int);
extern int islower(int);
extern int isprint(int);
extern int ispunct(int);
extern int isspace(int);
extern int isupper(int);
extern int isxdigit(int);
extern int tolower(int);
extern int toupper(int);




extern int isascii(int);
extern int toascii(int);
extern int _tolower(int);
extern int _toupper(int);



extern unsigned char __ctype[];
extern unsigned int *__ctype_mask;
extern int *__trans_upper;
extern int *__trans_lower;
# 163 "/usr/include/ctype.h" 3 4
}
# 34
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 2 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 1 3 4
# 35
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 2 3 4





extern "C" {
# 61
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
typedef long wint_t;





typedef int wctype_t;
# 103
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
typedef __mbstate_t mbstate_t;
# 113
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
extern int iswalpha(wint_t);
extern int iswupper(wint_t);
extern int iswlower(wint_t);
extern int iswdigit(wint_t);
extern int iswxdigit(wint_t);
extern int iswalnum(wint_t);
extern int iswspace(wint_t);
extern int iswpunct(wint_t);
extern int iswprint(wint_t);
extern int iswgraph(wint_t);
extern int iswcntrl(wint_t);
extern int iswctype(wint_t, wctype_t);
extern wint_t towlower(wint_t);
extern wint_t towupper(wint_t);
extern wint_t fgetwc(__FILE *);
extern wchar_t *fgetws(wchar_t *, int, __FILE *);
extern wint_t fputwc(wint_t, __FILE *);
extern int fputws(const wchar_t *, __FILE *);
extern wint_t ungetwc(wint_t, __FILE *);
extern wint_t getwc(__FILE *);
extern wint_t getwchar(void);
extern wint_t putwc(wint_t, __FILE *);
extern wint_t putwchar(wint_t);
extern double wcstod(const wchar_t *, wchar_t **);
extern long wcstol(const wchar_t *, wchar_t **, int);
extern unsigned long wcstoul(const wchar_t *, wchar_t **, int);
extern wchar_t *wcscat(wchar_t *, const wchar_t *);
extern wchar_t *wcschr(const wchar_t *, wchar_t);
extern int wcscmp(const wchar_t *, const wchar_t *);
extern int wcscoll(const wchar_t *, const wchar_t *);
extern wchar_t *wcscpy(wchar_t *, const wchar_t *);
extern size_t wcscspn(const wchar_t *, const wchar_t *);
extern size_t wcslen(const wchar_t *);
extern wchar_t *wcsncat(wchar_t *, const wchar_t *, size_t);
extern int wcsncmp(const wchar_t *, const wchar_t *, size_t);
extern wchar_t *wcsncpy(wchar_t *, const wchar_t *, size_t);
extern wchar_t *wcspbrk(const wchar_t *, const wchar_t *);
extern wchar_t *wcsrchr(const wchar_t *, wchar_t);
extern size_t wcsspn(const wchar_t *, const wchar_t *);
extern wchar_t *wcswcs(const wchar_t *, const wchar_t *);
extern int wcswidth(const wchar_t *, size_t);
extern size_t wcsxfrm(wchar_t *, const wchar_t *, size_t);
extern int wcwidth(const wchar_t);
extern wctype_t wctype(const char *);







extern wchar_t *wcstok(wchar_t *, const wchar_t *, wchar_t **);
extern size_t wcsftime(wchar_t *, size_t, const wchar_t *, const struct
tm *);
#pragma redefine_extname wcstok __wcstok_xpg5
#pragma redefine_extname wcsftime __wcsftime_xpg5
# 180
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
extern wint_t btowc(int);
extern int fwprintf(__FILE *, const wchar_t *, ...);
extern int fwscanf(__FILE *, const wchar_t *, ...);
extern int fwide(__FILE *, int);
extern int mbsinit(const mbstate_t *);
extern size_t mbrlen(const char *, size_t, mbstate_t *);
extern size_t mbrtowc(wchar_t *, const char *, size_t, mbstate_t *);
extern size_t mbsrtowcs(wchar_t *, const char **, size_t, mbstate_t *);
extern int swprintf(wchar_t *, size_t, const wchar_t *, ...);
extern int swscanf(const wchar_t *, const wchar_t *, ...);
extern int vfwprintf(__FILE *, const wchar_t *, __va_list);
extern int vwprintf(const wchar_t *, __va_list);
extern int vswprintf(wchar_t *, size_t, const wchar_t *, __va_list);
extern size_t wcrtomb(char *, wchar_t, mbstate_t *);
extern size_t wcsrtombs(char *, const wchar_t **, size_t, mbstate_t *);
extern wchar_t *wcsstr(const wchar_t *, const wchar_t *);
extern int wctob(wint_t);
extern wchar_t *wmemchr(const wchar_t *, wchar_t, size_t);
extern int wmemcmp(const wchar_t *, const wchar_t *, size_t);
extern wchar_t *wmemcpy(wchar_t *, const wchar_t *, size_t);
extern wchar_t *wmemmove(wchar_t *, const wchar_t *, size_t);
extern wchar_t *wmemset(wchar_t *, wchar_t, size_t);
extern int wprintf(const wchar_t *, ...);
extern int wscanf(const wchar_t *, ...);
# 307
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
#pragma redefine_extname fgetwc __fgetwc_xpg5
#pragma redefine_extname getwc __getwc_xpg5
#pragma redefine_extname getwchar __getwchar_xpg5
#pragma redefine_extname fputwc __fputwc_xpg5
#pragma redefine_extname putwc __putwc_xpg5
#pragma redefine_extname putwchar __putwchar_xpg5
#pragma redefine_extname fgetws __fgetws_xpg5
#pragma redefine_extname fputws __fputws_xpg5
#pragma redefine_extname ungetwc __ungetwc_xpg5
# 352
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
}
# 55 "/usr/local/fitools/include/g++-v3/cwchar" 2 3
# 69 "/usr/local/fitools/include/g++-v3/cwchar" 3
namespace std
{
  using ::mbstate_t;
}
# 46 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 2 3

namespace std
{



  template<typename _StateT>
    class fpos
    {
    public:

      typedef _StateT __state_type;

    private:
      streamoff _M_off;
      __state_type _M_st;

    public:
      __state_type
      state() const { return _M_st; }

      void
      state(__state_type __st) { _M_st = __st; }



      fpos(): _M_off(streamoff()), _M_st(__state_type()) { }

      fpos(streamoff __off, __state_type __st = __state_type())
      : _M_off(__off), _M_st(__st) { }

      operator streamoff() const { return _M_off; }

      fpos&
      operator+=(streamoff __off) { _M_off += __off; return *this; }

      fpos&
      operator-=(streamoff __off) { _M_off -= __off; return *this; }

      fpos
      operator+(streamoff __off)
      {
        fpos __t(*this);
        __t += __off;
        return __t;
      }

      fpos
      operator-(streamoff __off)
      {
        fpos __t(*this);
        __t -= __off;
        return __t;
      }

      bool
      operator==(const fpos& __pos) const
      { return _M_off == __pos._M_off; }

      bool
      operator!=(const fpos& __pos) const
      { return _M_off != __pos._M_off; }

      streamoff
      _M_position() const { return _M_off; }

      void
      _M_position(streamoff __off) { _M_off = __off; }
    };


  typedef fpos<mbstate_t> streampos;



}
# 47 "/usr/local/fitools/include/g++-v3/iosfwd" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/functexcept.h" 1 3
# 34 "/usr/local/fitools/include/g++-v3/bits/functexcept.h" 3
# 1 "/usr/local/fitools/include/g++-v3/exception_defines.h" 1 3
# 35 "/usr/local/fitools/include/g++-v3/bits/functexcept.h" 2 3

namespace std
{

  void
  __throw_bad_exception(void);


  void
  __throw_bad_alloc(void);


  void
  __throw_bad_cast(void);

  void
  __throw_bad_typeid(void);


  void
  __throw_logic_error(const char* __s);

  void
  __throw_domain_error(const char* __s);

  void
  __throw_invalid_argument(const char* __s);

  void
  __throw_length_error(const char* __s);

  void
  __throw_out_of_range(const char* __s);

  void
  __throw_runtime_error(const char* __s);

  void
  __throw_range_error(const char* __s);

  void
  __throw_overflow_error(const char* __s);

  void
  __throw_underflow_error(const char* __s);


  void
  __throw_ios_failure(const char* __s);
}
# 48 "/usr/local/fitools/include/g++-v3/iosfwd" 2 3

namespace std
{
  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ios;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_streambuf;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_istream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ostream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_iostream;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
            typename _Alloc = allocator<_CharT> >
    class basic_stringbuf;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_istringstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_ostringstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_stringstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_filebuf;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ifstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ofstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_fstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class istreambuf_iterator;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class ostreambuf_iterator;



  class ios_base;


  typedef basic_ios<char> ios;
  typedef basic_streambuf<char> streambuf;
  typedef basic_istream<char> istream;
  typedef basic_ostream<char> ostream;
  typedef basic_iostream<char> iostream;
  typedef basic_stringbuf<char> stringbuf;
  typedef basic_istringstream<char> istringstream;
  typedef basic_ostringstream<char> ostringstream;
  typedef basic_stringstream<char> stringstream;
  typedef basic_filebuf<char> filebuf;
  typedef basic_ifstream<char> ifstream;
  typedef basic_ofstream<char> ofstream;
  typedef basic_fstream<char> fstream;

  typedef basic_ios<wchar_t> wios;
  typedef basic_streambuf<wchar_t> wstreambuf;
  typedef basic_istream<wchar_t> wistream;
  typedef basic_ostream<wchar_t> wostream;
  typedef basic_iostream<wchar_t> wiostream;
  typedef basic_stringbuf<wchar_t> wstringbuf;
  typedef basic_istringstream<wchar_t> wistringstream;
  typedef basic_ostringstream<wchar_t> wostringstream;
  typedef basic_stringstream<wchar_t> wstringstream;
  typedef basic_filebuf<wchar_t> wfilebuf;
  typedef basic_ifstream<wchar_t> wifstream;
  typedef basic_ofstream<wchar_t> wofstream;
  typedef basic_fstream<wchar_t> wfstream;
}
# 71 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_pair.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_pair.h" 3
namespace std
{


template <class _T1, class _T2>
struct pair {
  typedef _T1 first_type;
  typedef _T2 second_type;

  _T1 first;
  _T2 second;




  pair() : first(), second() {}




  pair(const _T1& __a, const _T2& __b) : first(__a), second(__b) {}


  template <class _U1, class _U2>
  pair(const pair<_U1, _U2>& __p) : first(__p.first), second(__p.second)
{}
};


template <class _T1, class _T2>
inline bool operator==(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y)
{
  return __x.first == __y.first && __x.second == __y.second;
}


template <class _T1, class _T2>
inline bool operator<(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y)
{
  return __x.first < __y.first ||
         (!(__y.first < __x.first) && __x.second < __y.second);
}


template <class _T1, class _T2>
inline bool operator!=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return !(__x == __y);
}


template <class _T1, class _T2>
inline bool operator>(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return __y < __x;
}


template <class _T1, class _T2>
inline bool operator<=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return !(__y < __x);
}


template <class _T1, class _T2>
inline bool operator>=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return !(__x < __y);
}
# 140 "/usr/local/fitools/include/g++-v3/bits/stl_pair.h" 3
template <class _T1, class _T2>


inline pair<_T1, _T2> make_pair(_T1 __x, _T2 __y)



{
  return pair<_T1, _T2>(__x, __y);
}

}
# 72 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 1 3
# 53 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 3
# 90 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 3
struct __true_type {};
struct __false_type {};

template <class _Tp>
struct __type_traits {
   typedef __true_type this_dummy_member_must_be_first;
# 113 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 3
   typedef __false_type has_trivial_default_constructor;
   typedef __false_type has_trivial_copy_constructor;
   typedef __false_type has_trivial_assignment_operator;
   typedef __false_type has_trivial_destructor;
   typedef __false_type is_POD_type;
};




template<> struct __type_traits<bool> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<char> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<signed char> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned char> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<wchar_t> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<short> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned short> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<int> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned int> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<long long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned long long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<float> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<double> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<long double> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template <class _Tp>
struct __type_traits<_Tp*> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};





template <class _Tp> struct _Is_integer {
  typedef __false_type _Integral;
};

template<> struct _Is_integer<bool> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<char> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<signed char> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned char> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<wchar_t> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<short> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned short> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<int> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned int> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<long> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned long> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<long long> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned long long> {
  typedef __true_type _Integral;
};

template<typename _Tp> struct _Is_normal_iterator {
   typedef __false_type _Normal;
};


namespace __gnu_cxx
{
  template<typename _Iterator, typename _Container> class
__normal_iterator;
}

template<typename _Iterator, typename _Container>
struct _Is_normal_iterator< __gnu_cxx::__normal_iterator<_Iterator,
_Container> > {
   typedef __true_type _Normal;
};
# 73 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h" 1
3
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h"
3

namespace std
{
# 80 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h"
3
  struct input_iterator_tag {};

  struct output_iterator_tag {};

  struct forward_iterator_tag : public input_iterator_tag {};

  struct bidirectional_iterator_tag : public forward_iterator_tag {};

  struct random_access_iterator_tag : public bidirectional_iterator_tag
{};
# 100 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h"
3
  template<typename _Category, typename _Tp, typename _Distance =
ptrdiff_t,
           typename _Pointer = _Tp*, typename _Reference = _Tp&>
    struct iterator {

      typedef _Category iterator_category;

      typedef _Tp value_type;

      typedef _Distance difference_type;

      typedef _Pointer pointer;

      typedef _Reference reference;
    };







  template<typename _Iterator>
    struct iterator_traits {
      typedef typename _Iterator::iterator_category iterator_category;
      typedef typename _Iterator::value_type value_type;
      typedef typename _Iterator::difference_type difference_type;
      typedef typename _Iterator::pointer pointer;
      typedef typename _Iterator::reference reference;
    };

  template<typename _Tp>
    struct iterator_traits<_Tp*> {
      typedef random_access_iterator_tag iterator_category;
      typedef _Tp value_type;
      typedef ptrdiff_t difference_type;
      typedef _Tp* pointer;
      typedef _Tp& reference;
    };

  template<typename _Tp>
    struct iterator_traits<const _Tp*> {
      typedef random_access_iterator_tag iterator_category;
      typedef _Tp value_type;
      typedef ptrdiff_t difference_type;
      typedef const _Tp* pointer;
      typedef const _Tp& reference;
    };







  template<typename _Iter>
    inline typename iterator_traits<_Iter>::iterator_category
    __iterator_category(const _Iter&)
    { return typename iterator_traits<_Iter>::iterator_category(); }

}
# 74 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h" 1
3
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
3
# 1 "/usr/local/fitools/include/g++-v3/bits/concept_check.h" 1 3
# 39 "/usr/local/fitools/include/g++-v3/bits/concept_check.h" 3
# 69 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
2 3




namespace std
{
template<typename _InputIterator>
  inline typename iterator_traits<_InputIterator>::difference_type
  __distance(_InputIterator __first, _InputIterator __last,
input_iterator_tag)
  {



    typename iterator_traits<_InputIterator>::difference_type __n = 0;
    while (__first != __last) {
      ++__first; ++__n;
    }
    return __n;
  }

template<typename _RandomAccessIterator>
  inline typename
iterator_traits<_RandomAccessIterator>::difference_type
  __distance(_RandomAccessIterator __first, _RandomAccessIterator
__last,
             random_access_iterator_tag)
  {


    return __last - __first;
  }
# 111 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
3
template<typename _InputIterator>
  inline typename iterator_traits<_InputIterator>::difference_type
  distance(_InputIterator __first, _InputIterator __last)
  {

    return __distance(__first, __last, __iterator_category(__first));
  }

template<typename _InputIter, typename _Distance>
  inline void
  __advance(_InputIter& __i, _Distance __n, input_iterator_tag)
  {


    while (__n--) ++__i;
  }

template<typename _BidirectionalIterator, typename _Distance>
  inline void
  __advance(_BidirectionalIterator& __i, _Distance __n,
            bidirectional_iterator_tag)
  {



    if (__n > 0)
      while (__n--) ++__i;
    else
      while (__n++) --__i;
  }

template<typename _RandomAccessIterator, typename _Distance>
  inline void
  __advance(_RandomAccessIterator& __i, _Distance __n,
            random_access_iterator_tag)
  {


    __i += __n;
  }
# 164 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
3
template<typename _InputIterator, typename _Distance>
  inline void
  advance(_InputIterator& __i, _Distance __n)
  {

    __advance(__i, __n, __iterator_category(__i));
  }

}
# 75 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 1 3
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
namespace std
{
# 89 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Iterator>
    class reverse_iterator
    : public iterator<typename
iterator_traits<_Iterator>::iterator_category,
                      typename iterator_traits<_Iterator>::value_type,
                      typename
iterator_traits<_Iterator>::difference_type,
                      typename iterator_traits<_Iterator>::pointer,
                      typename iterator_traits<_Iterator>::reference>
    {
    protected:
      _Iterator current;

    public:
      typedef _Iterator iterator_type;
      typedef typename iterator_traits<_Iterator>::difference_type

difference_type;
      typedef typename iterator_traits<_Iterator>::reference reference;
      typedef typename iterator_traits<_Iterator>::pointer pointer;

    public:



      reverse_iterator() { }




      explicit
      reverse_iterator(iterator_type __x) : current(__x) { }




      reverse_iterator(const reverse_iterator& __x)
      : current(__x.current) { }





      template<typename _Iter>
        reverse_iterator(const reverse_iterator<_Iter>& __x)
        : current(__x.base()) { }




      iterator_type
      base() const { return current; }






      reference
      operator*() const
      {
        _Iterator __tmp = current;
        return *--__tmp;
      }






      pointer
      operator->() const { return &(operator*()); }






      reverse_iterator&
      operator++()
      {
        --current;
        return *this;
      }






      reverse_iterator
      operator++(int)
      {
        reverse_iterator __tmp = *this;
        --current;
        return __tmp;
      }






      reverse_iterator&
      operator--()
      {
        ++current;
        return *this;
      }






      reverse_iterator operator--(int)
      {
        reverse_iterator __tmp = *this;
        ++current;
        return __tmp;
      }






      reverse_iterator
      operator+(difference_type __n) const
      { return reverse_iterator(current - __n); }






      reverse_iterator&
      operator+=(difference_type __n)
      {
        current -= __n;
        return *this;
      }






      reverse_iterator
      operator-(difference_type __n) const
      { return reverse_iterator(current + __n); }






      reverse_iterator&
      operator-=(difference_type __n)
      {
        current += __n;
        return *this;
      }






      reference
      operator[](difference_type __n) const { return *(*this + __n); }
    };
# 269 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Iterator>
    inline bool
    operator==(const reverse_iterator<_Iterator>& __x,
               const reverse_iterator<_Iterator>& __y)
    { return __x.base() == __y.base(); }

  template<typename _Iterator>
    inline bool
    operator<(const reverse_iterator<_Iterator>& __x,
              const reverse_iterator<_Iterator>& __y)
    { return __y.base() < __x.base(); }

  template<typename _Iterator>
    inline bool
    operator!=(const reverse_iterator<_Iterator>& __x,
               const reverse_iterator<_Iterator>& __y)
    { return !(__x == __y); }

  template<typename _Iterator>
    inline bool
    operator>(const reverse_iterator<_Iterator>& __x,
              const reverse_iterator<_Iterator>& __y)
    { return __y < __x; }

  template<typename _Iterator>
    inline bool
    operator<=(const reverse_iterator<_Iterator>& __x,
                const reverse_iterator<_Iterator>& __y)
    { return !(__y < __x); }

  template<typename _Iterator>
    inline bool
    operator>=(const reverse_iterator<_Iterator>& __x,
               const reverse_iterator<_Iterator>& __y)
    { return !(__x < __y); }

  template<typename _Iterator>
    inline typename reverse_iterator<_Iterator>::difference_type
    operator-(const reverse_iterator<_Iterator>& __x,
              const reverse_iterator<_Iterator>& __y)
    { return __y.base() - __x.base(); }

  template<typename _Iterator>
    inline reverse_iterator<_Iterator>
    operator+(typename reverse_iterator<_Iterator>::difference_type __n,
              const reverse_iterator<_Iterator>& __x)
    { return reverse_iterator<_Iterator>(__x.base() - __n); }
# 327 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    class back_insert_iterator
    : public iterator<output_iterator_tag, void, void, void, void>
    {
    protected:
      _Container* container;

    public:

      typedef _Container container_type;


      explicit
      back_insert_iterator(_Container& __x) : container(&__x) { }
# 353 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
      back_insert_iterator&
      operator=(typename _Container::const_reference __value)
      {
        container->push_back(__value);
        return *this;
      }


      back_insert_iterator&
      operator*() { return *this; }


      back_insert_iterator&
      operator++() { return *this; }


      back_insert_iterator
      operator++(int) { return *this; }
    };
# 384 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    inline back_insert_iterator<_Container>
    back_inserter(_Container& __x)
    { return back_insert_iterator<_Container>(__x); }
# 397 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    class front_insert_iterator
    : public iterator<output_iterator_tag, void, void, void, void>
    {
    protected:
      _Container* container;

    public:

      typedef _Container container_type;


      explicit front_insert_iterator(_Container& __x) : container(&__x)
{ }
# 422 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
      front_insert_iterator&
      operator=(typename _Container::const_reference __value)
      {
        container->push_front(__value);
        return *this;
      }


      front_insert_iterator&
      operator*() { return *this; }


      front_insert_iterator&
      operator++() { return *this; }


      front_insert_iterator
      operator++(int) { return *this; }
    };
# 453 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    inline front_insert_iterator<_Container>
    front_inserter(_Container& __x)
    { return front_insert_iterator<_Container>(__x); }
# 470 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    class insert_iterator
    : public iterator<output_iterator_tag, void, void, void, void>
    {
    protected:
      _Container* container;
      typename _Container::iterator iter;

    public:

      typedef _Container container_type;





      insert_iterator(_Container& __x, typename _Container::iterator
__i)
      : container(&__x), iter(__i) {}
# 512 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
      insert_iterator&
      operator=(const typename _Container::const_reference __value)
      {
        iter = container->insert(iter, __value);
        ++iter;
        return *this;
      }


      insert_iterator&
      operator*() { return *this; }


      insert_iterator&
      operator++() { return *this; }


      insert_iterator&
      operator++(int) { return *this; }
    };
# 544 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container, typename _Iterator>
    inline insert_iterator<_Container>
    inserter(_Container& __x, _Iterator __i)
    {
      return insert_iterator<_Container>(__x,
                                         typename
_Container::iterator(__i));
    }
}

namespace __gnu_cxx
{







  using std::iterator_traits;
  using std::iterator;
  template<typename _Iterator, typename _Container>
    class __normal_iterator
      : public iterator<typename
iterator_traits<_Iterator>::iterator_category,
                        typename iterator_traits<_Iterator>::value_type,
                        typename
iterator_traits<_Iterator>::difference_type,
                        typename iterator_traits<_Iterator>::pointer,
                        typename iterator_traits<_Iterator>::reference>
    {
    protected:
      _Iterator _M_current;

    public:
      typedef typename iterator_traits<_Iterator>::difference_type

difference_type;
      typedef typename iterator_traits<_Iterator>::reference reference;
      typedef typename iterator_traits<_Iterator>::pointer pointer;

      __normal_iterator() : _M_current(_Iterator()) { }

      explicit
      __normal_iterator(const _Iterator& __i) : _M_current(__i) { }


      template<typename _Iter>
      inline __normal_iterator(const __normal_iterator<_Iter,
_Container>& __i)
        : _M_current(__i.base()) { }


      reference
      operator*() const { return *_M_current; }

      pointer
      operator->() const { return _M_current; }

      __normal_iterator&
      operator++() { ++_M_current; return *this; }

      __normal_iterator
      operator++(int) { return __normal_iterator(_M_current++); }


      __normal_iterator&
      operator--() { --_M_current; return *this; }

      __normal_iterator
      operator--(int) { return __normal_iterator(_M_current--); }


      reference
      operator[](const difference_type& __n) const
      { return _M_current[__n]; }

      __normal_iterator&
      operator+=(const difference_type& __n)
      { _M_current += __n; return *this; }

      __normal_iterator
      operator+(const difference_type& __n) const
      { return __normal_iterator(_M_current + __n); }

      __normal_iterator&
      operator-=(const difference_type& __n)
      { _M_current -= __n; return *this; }

      __normal_iterator
      operator-(const difference_type& __n) const
      { return __normal_iterator(_M_current - __n); }

      difference_type
      operator-(const __normal_iterator& __i) const
      { return _M_current - __i._M_current; }

      const _Iterator&
      base() const { return _M_current; }
    };
# 649 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator==(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() == __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator==(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() == __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator!=(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() != __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator!=(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() != __rhs.base(); }


  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator<(const __normal_iterator<_IteratorL, _Container>& __lhs,
            const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() < __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator<(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() < __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator>(const __normal_iterator<_IteratorL, _Container>& __lhs,
            const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() > __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator>(const __normal_iterator<_Iterator, _Container>& __lhs,
            const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() > __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator<=(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() <= __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator<=(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() <= __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator>=(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() >= __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator>=(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() >= __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline __normal_iterator<_Iterator, _Container>
  operator+(typename __normal_iterator<_Iterator,
_Container>::difference_type __n,
            const __normal_iterator<_Iterator, _Container>& __i)
  { return __normal_iterator<_Iterator, _Container>(__i.base() + __n); }
}
# 76 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3


namespace std
{
# 91 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    inline void
    iter_swap(_ForwardIter1 __a, _ForwardIter2 __b)
    {
      typedef typename iterator_traits<_ForwardIter1>::value_type
_ValueType1;
      typedef typename iterator_traits<_ForwardIter2>::value_type
_ValueType2;







      _ValueType1 __tmp = *__a;
      *__a = *__b;
      *__b = __tmp;
    }
# 118 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp>
    inline void
    swap(_Tp& __a, _Tp& __b)
    {



      _Tp __tmp = __a;
      __a = __b;
      __b = __tmp;
    }
# 146 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp>
    inline const _Tp&
    min(const _Tp& __a, const _Tp& __b)
    {



      if (__b < __a) return __b; return __a;
    }
# 166 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp>
    inline const _Tp&
    max(const _Tp& __a, const _Tp& __b)
    {



      if (__a < __b) return __b; return __a;
    }
# 186 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp, typename _Compare>
    inline const _Tp&
    min(const _Tp& __a, const _Tp& __b, _Compare __comp)
    {

      if (__comp(__b, __a)) return __b; return __a;
    }
# 204 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp, typename _Compare>
    inline const _Tp&
    max(const _Tp& __a, const _Tp& __b, _Compare __comp)
    {

      if (__comp(__a, __b)) return __b; return __a;
    }
# 221 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy(_InputIter __first, _InputIter __last,
           _OutputIter __result,
           input_iterator_tag)
    {
      for ( ; __first != __last; ++__result, ++__first)
        *__result = *__first;
      return __result;
    }

  template<typename _RandomAccessIter, typename _OutputIter>
    inline _OutputIter
    __copy(_RandomAccessIter __first, _RandomAccessIter __last,
           _OutputIter __result,
           random_access_iterator_tag)
    {
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type
          _Distance;
      for (_Distance __n = __last - __first; __n > 0; --__n) {
        *__result = *__first;
        ++__first;
        ++__result;
      }
      return __result;
    }

  template<typename _Tp>
    inline _Tp*
    __copy_trivial(const _Tp* __first, const _Tp* __last, _Tp* __result)
    {
      memmove(__result, __first, sizeof(_Tp) * (__last - __first));
      return __result + (__last - __first);
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_aux2(_InputIter __first, _InputIter __last,
                _OutputIter __result, __false_type)
    { return __copy(__first, __last, __result,
__iterator_category(__first)); }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_aux2(_InputIter __first, _InputIter __last,
                _OutputIter __result, __true_type)
    { return __copy(__first, __last, __result,
__iterator_category(__first)); }

  template<typename _Tp>
    inline _Tp*
    __copy_aux2(_Tp* __first, _Tp* __last,
                _Tp* __result, __true_type)
    { return __copy_trivial(__first, __last, __result); }

  template<typename _Tp>
    inline _Tp*
    __copy_aux2(const _Tp* __first, const _Tp* __last,
                _Tp* __result, __true_type)
    { return __copy_trivial(__first, __last, __result); }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni2(_InputIter __first, _InputIter __last,
               _OutputIter __result, __true_type)
    {
      typedef typename iterator_traits<_InputIter>::value_type
          _ValueType;
      typedef typename
__type_traits<_ValueType>::has_trivial_assignment_operator
          _Trivial;
      return _OutputIter(__copy_aux2(__first, __last,
                                     __result.base(),
                                     _Trivial()));
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni2(_InputIter __first, _InputIter __last,
               _OutputIter __result, __false_type)
    {
      typedef typename iterator_traits<_InputIter>::value_type
          _ValueType;
      typedef typename
__type_traits<_ValueType>::has_trivial_assignment_operator
          _Trivial;
      return __copy_aux2(__first, __last,
                         __result,
                         _Trivial());
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni1(_InputIter __first, _InputIter __last,
               _OutputIter __result, __true_type)
    {
      typedef typename _Is_normal_iterator<_OutputIter>::_Normal
__Normal;
      return __copy_ni2(__first.base(), __last.base(), __result,
__Normal());
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni1(_InputIter __first, _InputIter __last,
               _OutputIter __result, __false_type)
    {
      typedef typename _Is_normal_iterator<_OutputIter>::_Normal
__Normal;
      return __copy_ni2(__first, __last, __result, __Normal());
    }
# 339 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    copy(_InputIter __first, _InputIter __last, _OutputIter __result)
    {





       typedef typename _Is_normal_iterator<_InputIter>::_Normal
__Normal;
       return __copy_ni1(__first, __last, __result, __Normal());
    }




  template<typename _BidirectionalIter1, typename _BidirectionalIter2>
    inline _BidirectionalIter2
    __copy_backward(_BidirectionalIter1 __first, _BidirectionalIter1
__last,
                    _BidirectionalIter2 __result,
                    bidirectional_iterator_tag)
    {
      while (__first != __last)
        *--__result = *--__last;
      return __result;
    }

  template<typename _RandomAccessIter, typename _BidirectionalIter>
    inline _BidirectionalIter
    __copy_backward(_RandomAccessIter __first, _RandomAccessIter __last,
                    _BidirectionalIter __result,
                    random_access_iterator_tag)
    {
      typename iterator_traits<_RandomAccessIter>::difference_type __n;
      for (__n = __last - __first; __n > 0; --__n)
        *--__result = *--__last;
      return __result;
    }







  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BoolType>
    struct __copy_backward_dispatch
    {
      static _BidirectionalIter2
      copy(_BidirectionalIter1 __first, _BidirectionalIter1 __last,
           _BidirectionalIter2 __result)
      {
        return __copy_backward(__first, __last,
                               __result,
                               __iterator_category(__first));
      }
    };

  template<typename _Tp>
    struct __copy_backward_dispatch<_Tp*, _Tp*, __true_type>
    {
      static _Tp*
      copy(const _Tp* __first, const _Tp* __last, _Tp* __result)
      {
        const ptrdiff_t _Num = __last - __first;
        memmove(__result - _Num, __first, sizeof(_Tp) * _Num);
        return __result - _Num;
      }
    };

  template<typename _Tp>
    struct __copy_backward_dispatch<const _Tp*, _Tp*, __true_type>
    {
      static _Tp*
      copy(const _Tp* __first, const _Tp* __last, _Tp* __result)
      {
        return __copy_backward_dispatch<_Tp*, _Tp*, __true_type>
          ::copy(__first, __last, __result);
      }
    };

  template<typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_aux(_BI1 __first, _BI1 __last, _BI2 __result)
    {
      typedef typename __type_traits<typename
iterator_traits<_BI2>::value_type>
                            ::has_trivial_assignment_operator _Trivial;
      return __copy_backward_dispatch<_BI1, _BI2, _Trivial>
                  ::copy(__first, __last, __result);
    }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_output_normal_iterator(_BI1 __first, _BI1 __last,
                                           _BI2 __result, __true_type)
    { return _BI2(__copy_backward_aux(__first, __last,
__result.base())); }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_output_normal_iterator(_BI1 __first, _BI1 __last,
                                           _BI2 __result, __false_type)
    { return __copy_backward_aux(__first, __last, __result); }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_input_normal_iterator(_BI1 __first, _BI1 __last,
                                          _BI2 __result, __true_type)
    {
      typedef typename _Is_normal_iterator<_BI2>::_Normal __Normal;
      return __copy_backward_output_normal_iterator(__first.base(),
__last.base(),
                                                    __result,
__Normal());
    }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_input_normal_iterator(_BI1 __first, _BI1 __last,
                                          _BI2 __result, __false_type)
    {
      typedef typename _Is_normal_iterator<_BI2>::_Normal __Normal;
      return __copy_backward_output_normal_iterator(__first, __last,
__result,
                                                    __Normal());
    }
# 477 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template <typename _BI1, typename _BI2>
    inline _BI2
    copy_backward(_BI1 __first, _BI1 __last, _BI2 __result)
    {







      typedef typename _Is_normal_iterator<_BI1>::_Normal __Normal;
      return __copy_backward_input_normal_iterator(__first, __last,
__result,
                                                   __Normal());
    }
# 509 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _ForwardIter, typename _Tp>
    void
    fill(_ForwardIter __first, _ForwardIter __last, const _Tp& __value)
    {



      for ( ; __first != __last; ++__first)
        *__first = __value;
    }
# 531 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _OutputIter, typename _Size, typename _Tp>
    _OutputIter
    fill_n(_OutputIter __first, _Size __n, const _Tp& __value)
    {



      for ( ; __n > 0; --__n, ++__first)
        *__first = __value;
      return __first;
    }



  inline void
  fill(unsigned char* __first, unsigned char* __last, const unsigned
char& __c)
  {
    unsigned char __tmp = __c;
    memset(__first, __tmp, __last - __first);
  }

  inline void
  fill(signed char* __first, signed char* __last, const signed char&
__c)
  {
    signed char __tmp = __c;
    memset(__first, static_cast<unsigned char>(__tmp), __last -
__first);
  }

  inline void
  fill(char* __first, char* __last, const char& __c)
  {
    char __tmp = __c;
    memset(__first, static_cast<unsigned char>(__tmp), __last -
__first);
  }

  template<typename _Size>
    inline unsigned char*
    fill_n(unsigned char* __first, _Size __n, const unsigned char& __c)
    {
      fill(__first, __first + __n, __c);
      return __first + __n;
    }

  template<typename _Size>
    inline signed char*
    fill_n(char* __first, _Size __n, const signed char& __c)
    {
      fill(__first, __first + __n, __c);
      return __first + __n;
    }

  template<typename _Size>
    inline char*
    fill_n(char* __first, _Size __n, const char& __c)
    {
      fill(__first, __first + __n, __c);
      return __first + __n;
    }
# 606 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2>
    pair<_InputIter1, _InputIter2>
    mismatch(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2)
    {








      while (__first1 != __last1 && *__first1 == *__first2) {
        ++__first1;
        ++__first2;
      }
      return pair<_InputIter1, _InputIter2>(__first1, __first2);
    }
# 640 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_BinaryPredicate>
    pair<_InputIter1, _InputIter2>
    mismatch(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2,
             _BinaryPredicate __binary_pred)
    {




      while (__first1 != __last1 && __binary_pred(*__first1, *__first2))
{
        ++__first1;
        ++__first2;
      }
      return pair<_InputIter1, _InputIter2>(__first1, __first2);
    }
# 668 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2>
    inline bool
    equal(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2)
    {







      for ( ; __first1 != __last1; ++__first1, ++__first2)
        if (!(*__first1 == *__first2))
          return false;
      return true;
    }
# 699 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_BinaryPredicate>
    inline bool
    equal(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2,
          _BinaryPredicate __binary_pred)
    {




      for ( ; __first1 != __last1; ++__first1, ++__first2)
        if (!__binary_pred(*__first1, *__first2))
          return false;
      return true;
    }
# 732 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2>
    bool
    lexicographical_compare(_InputIter1 __first1, _InputIter1 __last1,
                            _InputIter2 __first2, _InputIter2 __last2)
    {








      for ( ; __first1 != __last1 && __first2 != __last2
            ; ++__first1, ++__first2) {
        if (*__first1 < *__first2)
          return true;
        if (*__first2 < *__first1)
          return false;
      }
      return __first1 == __last1 && __first2 != __last2;
    }
# 767 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_Compare>
    bool
    lexicographical_compare(_InputIter1 __first1, _InputIter1 __last1,
                            _InputIter2 __first2, _InputIter2 __last2,
                            _Compare __comp)
    {




      for ( ; __first1 != __last1 && __first2 != __last2
            ; ++__first1, ++__first2) {
        if (__comp(*__first1, *__first2))
          return true;
        if (__comp(*__first2, *__first1))
          return false;
      }
      return __first1 == __last1 && __first2 != __last2;
    }

  inline bool
  lexicographical_compare(const unsigned char* __first1, const unsigned
char* __last1,
                          const unsigned char* __first2, const unsigned
char* __last2)
  {
    const size_t __len1 = __last1 - __first1;
    const size_t __len2 = __last2 - __first2;
    const int __result = memcmp(__first1, __first2, min(__len1,
__len2));
    return __result != 0 ? __result < 0 : __len1 < __len2;
  }

  inline bool
  lexicographical_compare(const char* __first1, const char* __last1,
                          const char* __first2, const char* __last2)
  {

    return lexicographical_compare((const signed char*) __first1,
                                   (const signed char*) __last1,
                                   (const signed char*) __first2,
                                   (const signed char*) __last2);






  }

}
# 67 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 1 3
# 67 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
namespace std
{






  template <class _T1, class _T2>
    inline void
    _Construct(_T1* __p, const _T2& __value)
    { new (static_cast<void*>(__p)) _T1(__value); }







  template <class _T1>
    inline void
    _Construct(_T1* __p)
    { new (static_cast<void*>(__p)) _T1(); }
# 98 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
  template <class _ForwardIterator>
    inline void
    __destroy_aux(_ForwardIterator __first, _ForwardIterator __last,
__false_type)
    { for ( ; __first != __last; ++__first) _Destroy(&*__first); }
# 112 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
  template <class _ForwardIterator>
    inline void
    __destroy_aux(_ForwardIterator, _ForwardIterator, __true_type)
    { }






  template <class _Tp>
    inline void
    _Destroy(_Tp* __pointer)
    { __pointer->~_Tp(); }
# 134 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
  template <class _ForwardIterator>
    inline void
    _Destroy(_ForwardIterator __first, _ForwardIterator __last)
    {
      typedef typename iterator_traits<_ForwardIterator>::value_type
                       _Value_type;
      typedef typename
__type_traits<_Value_type>::has_trivial_destructor
                       _Has_trivial_destructor;

      __destroy_aux(__first, __last, _Has_trivial_destructor());
    }
}
# 68 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 1 3
# 66 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
namespace std
{



  template<typename _InputIter, typename _ForwardIter>
    inline _ForwardIter
    __uninitialized_copy_aux(_InputIter __first, _InputIter __last,
                             _ForwardIter __result,
                             __true_type)
    { return copy(__first, __last, __result); }

  template<typename _InputIter, typename _ForwardIter>
    _ForwardIter
    __uninitialized_copy_aux(_InputIter __first, _InputIter __last,
                             _ForwardIter __result,
                             __false_type)
    {
      _ForwardIter __cur = __result;
      try {
        for ( ; __first != __last; ++__first, ++__cur)
          _Construct(&*__cur, *__first);
        return __cur;
      }
      catch(...)
        {
          _Destroy(__result, __cur);
          throw;
        }
    }
# 106 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _InputIter, typename _ForwardIter>
    inline _ForwardIter
    uninitialized_copy(_InputIter __first, _InputIter __last,
_ForwardIter __result)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename __type_traits<_ValueType>::is_POD_type _Is_POD;
      return __uninitialized_copy_aux(__first, __last, __result,
_Is_POD());
    }

  inline char*
  uninitialized_copy(const char* __first, const char* __last, char*
__result)
  {
    memmove(__result, __first, __last - __first);
    return __result + (__last - __first);
  }

  inline wchar_t*
  uninitialized_copy(const wchar_t* __first, const wchar_t* __last,
                     wchar_t* __result)
  {
    memmove(__result, __first, sizeof(wchar_t) * (__last - __first));
    return __result + (__last - __first);
  }



  template<typename _ForwardIter, typename _Tp>
    inline void
    __uninitialized_fill_aux(_ForwardIter __first, _ForwardIter __last,
                             const _Tp& __x, __true_type)
    { fill(__first, __last, __x); }

  template<typename _ForwardIter, typename _Tp>
    void
    __uninitialized_fill_aux(_ForwardIter __first, _ForwardIter __last,
                             const _Tp& __x, __false_type)
    {
      _ForwardIter __cur = __first;
      try {
        for ( ; __cur != __last; ++__cur)
          _Construct(&*__cur, __x);
      }
      catch(...)
        {
          _Destroy(__first, __cur);
          throw;
        }
    }
# 164 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _ForwardIter, typename _Tp>
    inline void
    uninitialized_fill(_ForwardIter __first, _ForwardIter __last, const
_Tp& __x)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename __type_traits<_ValueType>::is_POD_type _Is_POD;
      __uninitialized_fill_aux(__first, __last, __x, _Is_POD());
    }



  template<typename _ForwardIter, typename _Size, typename _Tp>
    inline _ForwardIter
    __uninitialized_fill_n_aux(_ForwardIter __first, _Size __n,
                               const _Tp& __x, __true_type)
    {
      return fill_n(__first, __n, __x);
    }

  template<typename _ForwardIter, typename _Size, typename _Tp>
    _ForwardIter
    __uninitialized_fill_n_aux(_ForwardIter __first, _Size __n,
                               const _Tp& __x, __false_type)
    {
      _ForwardIter __cur = __first;
      try {
        for ( ; __n > 0; --__n, ++__cur)
          _Construct(&*__cur, __x);
        return __cur;
      }
      catch(...)
        {
          _Destroy(__first, __cur);
          throw;
        }
    }
# 210 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _ForwardIter, typename _Size, typename _Tp>
    inline _ForwardIter
    uninitialized_fill_n(_ForwardIter __first, _Size __n, const _Tp&
__x)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename __type_traits<_ValueType>::is_POD_type _Is_POD;
      return __uninitialized_fill_n_aux(__first, __n, __x, _Is_POD());
    }
# 227 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_ForwardIter>
    inline _ForwardIter
    __uninitialized_copy_copy(_InputIter1 __first1, _InputIter1 __last1,
                              _InputIter2 __first2, _InputIter2 __last2,
                              _ForwardIter __result)
    {
      _ForwardIter __mid = uninitialized_copy(__first1, __last1,
__result);
      try {
        return uninitialized_copy(__first2, __last2, __mid);
      }
      catch(...)
        {
          _Destroy(__result, __mid);
          throw;
        }
    }




  template<typename _ForwardIter, typename _Tp, typename _InputIter>
    inline _ForwardIter
    __uninitialized_fill_copy(_ForwardIter __result, _ForwardIter __mid,
                              const _Tp& __x,
                              _InputIter __first, _InputIter __last)
    {
      uninitialized_fill(__result, __mid, __x);
      try {
        return uninitialized_copy(__first, __last, __mid);
      }
      catch(...)
        {
          _Destroy(__result, __mid);
          throw;
        }
    }




  template<typename _InputIter, typename _ForwardIter, typename _Tp>
    inline void
    __uninitialized_copy_fill(_InputIter __first1, _InputIter __last1,
                              _ForwardIter __first2, _ForwardIter
__last2,
                              const _Tp& __x)
    {
      _ForwardIter __mid2 = uninitialized_copy(__first1, __last1,
__first2);
      try {
        uninitialized_fill(__mid2, __last2, __x);
      }
      catch(...)
        {
          _Destroy(__first2, __mid2);
          throw;
        }
    }

}
# 69 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_heap.h" 1 3
# 63 "/usr/local/fitools/include/g++-v3/bits/stl_heap.h" 3
namespace std
{



  template<typename _RandomAccessIterator, typename _Distance, typename
_Tp>
    void
    __push_heap(_RandomAccessIterator __first,
                _Distance __holeIndex, _Distance __topIndex, _Tp
__value)
    {
      _Distance __parent = (__holeIndex - 1) / 2;
      while (__holeIndex > __topIndex && *(__first + __parent) <
__value) {
        *(__first + __holeIndex) = *(__first + __parent);
        __holeIndex = __parent;
        __parent = (__holeIndex - 1) / 2;
      }
      *(__first + __holeIndex) = __value;
    }

  template<typename _RandomAccessIterator>
    inline void
    push_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;






      __push_heap(__first, _DistanceType((__last - __first) - 1),
_DistanceType(0),
                  _ValueType(*(__last - 1)));
    }

  template<typename _RandomAccessIterator, typename _Distance, typename
_Tp,
            typename _Compare>
    void
    __push_heap(_RandomAccessIterator __first, _Distance __holeIndex,
                _Distance __topIndex, _Tp __value, _Compare __comp)
    {
      _Distance __parent = (__holeIndex - 1) / 2;
      while (__holeIndex > __topIndex && __comp(*(__first + __parent),
__value)) {
        *(__first + __holeIndex) = *(__first + __parent);
        __holeIndex = __parent;
        __parent = (__holeIndex - 1) / 2;
      }
      *(__first + __holeIndex) = __value;
    }

  template<typename _RandomAccessIterator, typename _Compare>
    inline void
    push_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
              _Compare __comp)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;





      __push_heap(__first, _DistanceType((__last - __first) - 1),
_DistanceType(0),
                  _ValueType(*(__last - 1)), __comp);
    }

  template<typename _RandomAccessIterator, typename _Distance, typename
_Tp>
    void
    __adjust_heap(_RandomAccessIterator __first, _Distance __holeIndex,
                  _Distance __len, _Tp __value)
    {
      _Distance __topIndex = __holeIndex;
      _Distance __secondChild = 2 * __holeIndex + 2;
      while (__secondChild < __len) {
        if (*(__first + __secondChild) < *(__first + (__secondChild -
1)))
          __secondChild--;
        *(__first + __holeIndex) = *(__first + __secondChild);
        __holeIndex = __secondChild;
        __secondChild = 2 * (__secondChild + 1);
      }
      if (__secondChild == __len) {
        *(__first + __holeIndex) = *(__first + (__secondChild - 1));
        __holeIndex = __secondChild - 1;
      }
      __push_heap(__first, __holeIndex, __topIndex, __value);
    }

  template<typename _RandomAccessIterator, typename _Tp>
    inline void
    __pop_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
               _RandomAccessIterator __result, _Tp __value)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type _Distance;
      *__result = *__first;
      __adjust_heap(__first, _Distance(0), _Distance(__last - __first),
__value);
    }

  template<typename _RandomAccessIterator>
    inline void
    pop_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type _ValueType;






      __pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last -
1)));
    }

  template<typename _RandomAccessIterator, typename _Distance,
           typename _Tp, typename _Compare>
    void
    __adjust_heap(_RandomAccessIterator __first, _Distance __holeIndex,
                  _Distance __len, _Tp __value, _Compare __comp)
    {
      _Distance __topIndex = __holeIndex;
      _Distance __secondChild = 2 * __holeIndex + 2;
      while (__secondChild < __len) {
        if (__comp(*(__first + __secondChild), *(__first +
(__secondChild - 1))))
          __secondChild--;
        *(__first + __holeIndex) = *(__first + __secondChild);
        __holeIndex = __secondChild;
        __secondChild = 2 * (__secondChild + 1);
      }
      if (__secondChild == __len) {
        *(__first + __holeIndex) = *(__first + (__secondChild - 1));
        __holeIndex = __secondChild - 1;
      }
      __push_heap(__first, __holeIndex, __topIndex, __value, __comp);
    }

  template<typename _RandomAccessIterator, typename _Tp, typename
_Compare>
    inline void
    __pop_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
               _RandomAccessIterator __result, _Tp __value, _Compare
__comp)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type _Distance;
      *__result = *__first;
      __adjust_heap(__first, _Distance(0), _Distance(__last - __first),
                    __value, __comp);
    }

  template<typename _RandomAccessIterator, typename _Compare>
    inline void
    pop_heap(_RandomAccessIterator __first,
             _RandomAccessIterator __last, _Compare __comp)
    {




      typedef typename
iterator_traits<_RandomAccessIterator>::value_type _ValueType;
      __pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last -
1)), __comp);
    }

  template<typename _RandomAccessIterator>
    void
    make_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;






      if (__last - __first < 2) return;
      _DistanceType __len = __last - __first;
      _DistanceType __parent = (__len - 2)/2;

      while (true) {
        __adjust_heap(__first, __parent, __len, _ValueType(*(__first +
__parent)));
        if (__parent == 0) return;
        __parent--;
      }
    }

  template<typename _RandomAccessIterator, typename _Compare>
    inline void
    make_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
              _Compare __comp)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;





      if (__last - __first < 2) return;
      _DistanceType __len = __last - __first;
      _DistanceType __parent = (__len - 2)/2;

      while (true) {
        __adjust_heap(__first, __parent, __len,
                      _ValueType(*(__first + __parent)), __comp);
        if (__parent == 0) return;
        __parent--;
      }
    }

  template<typename _RandomAccessIterator>
    void
    sort_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {






      while (__last - __first > 1)
        pop_heap(__first, __last--);
    }

  template<typename _RandomAccessIterator, typename _Compare>
    void
    sort_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
              _Compare __comp)
    {




      while (__last - __first > 1)
        pop_heap(__first, __last--, __comp);
    }

}
# 65 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_tempbuf.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_tempbuf.h" 3
namespace std
{
# 74 "/usr/local/fitools/include/g++-v3/bits/stl_tempbuf.h" 3
template <class _ForwardIterator, class _Tp>
  class _Temporary_buffer
{



  ptrdiff_t _M_original_len;
  ptrdiff_t _M_len;
  _Tp* _M_buffer;


  void _M_allocate_buffer() {
    _M_original_len = _M_len;
    _M_buffer = 0;

    if (_M_len > (ptrdiff_t)(2147483647 / sizeof(_Tp)))
      _M_len = 2147483647 / sizeof(_Tp);

    while (_M_len > 0) {
      _M_buffer = (_Tp*) malloc(_M_len * sizeof(_Tp));
      if (_M_buffer)
        break;
      _M_len /= 2;
    }
  }

  void _M_initialize_buffer(const _Tp&, __true_type) {}
  void _M_initialize_buffer(const _Tp& val, __false_type) {
    uninitialized_fill_n(_M_buffer, _M_len, val);
  }

public:

  ptrdiff_t size() const { return _M_len; }

  ptrdiff_t requested_size() const { return _M_original_len; }

  _Tp* begin() { return _M_buffer; }

  _Tp* end() { return _M_buffer + _M_len; }

  _Temporary_buffer(_ForwardIterator __first, _ForwardIterator __last) {

    typedef typename __type_traits<_Tp>::has_trivial_default_constructor
            _Trivial;

    try {
      _M_len = distance(__first, __last);
      _M_allocate_buffer();
      if (_M_len > 0)
        _M_initialize_buffer(*__first, _Trivial());
    }
    catch(...)
      {
        free(_M_buffer);
        _M_buffer = 0;
        _M_len = 0;
        throw;
      }
  }

  ~_Temporary_buffer() {
    _Destroy(_M_buffer, _M_buffer + _M_len);
    free(_M_buffer);
  }

private:

  _Temporary_buffer(const _Temporary_buffer&) {}
  void operator=(const _Temporary_buffer&) {}
};

}
# 66 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 2 3



namespace std
{
# 84 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _Tp>
  inline const _Tp&
    __median(const _Tp& __a, const _Tp& __b, const _Tp& __c)
    {


      if (__a < __b)
        if (__b < __c)
          return __b;
        else if (__a < __c)
          return __c;
        else
          return __a;
      else if (__a < __c)
        return __a;
      else if (__b < __c)
        return __c;
      else
        return __b;
    }
# 118 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _Tp, typename _Compare>
    inline const _Tp&
    __median(const _Tp& __a, const _Tp& __b, const _Tp& __c, _Compare
__comp)
    {


      if (__comp(__a, __b))
        if (__comp(__b, __c))
          return __b;
        else if (__comp(__a, __c))
          return __c;
        else
          return __a;
      else if (__comp(__a, __c))
        return __a;
      else if (__comp(__b, __c))
        return __c;
      else
        return __b;
    }
# 150 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Function>
    _Function
    for_each(_InputIter __first, _InputIter __last, _Function __f)
    {


      for ( ; __first != __last; ++__first)
        __f(*__first);
      return __f;
    }






  template<typename _InputIter, typename _Tp>
    inline _InputIter
    find(_InputIter __first, _InputIter __last,
         const _Tp& __val,
         input_iterator_tag)
    {
      while (__first != __last && !(*__first == __val))
        ++__first;
      return __first;
    }






  template<typename _InputIter, typename _Predicate>
    inline _InputIter
    find_if(_InputIter __first, _InputIter __last,
            _Predicate __pred,
            input_iterator_tag)
    {
      while (__first != __last && !__pred(*__first))
        ++__first;
      return __first;
    }






  template<typename _RandomAccessIter, typename _Tp>
    _RandomAccessIter
    find(_RandomAccessIter __first, _RandomAccessIter __last,
         const _Tp& __val,
         random_access_iterator_tag)
    {
      typename iterator_traits<_RandomAccessIter>::difference_type
__trip_count
        = (__last - __first) >> 2;

      for ( ; __trip_count > 0 ; --__trip_count) {
        if (*__first == __val) return __first;
        ++__first;

        if (*__first == __val) return __first;
        ++__first;

        if (*__first == __val) return __first;
        ++__first;

        if (*__first == __val) return __first;
        ++__first;
      }

      switch(__last - __first) {
      case 3:
        if (*__first == __val) return __first;
        ++__first;
      case 2:
        if (*__first == __val) return __first;
        ++__first;
      case 1:
        if (*__first == __val) return __first;
        ++__first;
      case 0:
      default:
        return __last;
      }
    }






  template<typename _RandomAccessIter, typename _Predicate>
    _RandomAccessIter
    find_if(_RandomAccessIter __first, _RandomAccessIter __last,
            _Predicate __pred,
            random_access_iterator_tag)
    {
      typename iterator_traits<_RandomAccessIter>::difference_type
__trip_count
        = (__last - __first) >> 2;

      for ( ; __trip_count > 0 ; --__trip_count) {
        if (__pred(*__first)) return __first;
        ++__first;

        if (__pred(*__first)) return __first;
        ++__first;

        if (__pred(*__first)) return __first;
        ++__first;

        if (__pred(*__first)) return __first;
        ++__first;
      }

      switch(__last - __first) {
      case 3:
        if (__pred(*__first)) return __first;
        ++__first;
      case 2:
        if (__pred(*__first)) return __first;
        ++__first;
      case 1:
        if (__pred(*__first)) return __first;
        ++__first;
      case 0:
      default:
        return __last;
      }
    }
# 289 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Tp>
    inline _InputIter
    find(_InputIter __first, _InputIter __last,
         const _Tp& __val)
    {




      return find(__first, __last, __val, __iterator_category(__first));
    }
# 309 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Predicate>
    inline _InputIter
    find_if(_InputIter __first, _InputIter __last,
            _Predicate __pred)
    {




      return find_if(__first, __last, __pred,
__iterator_category(__first));
    }
# 329 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter>
    _ForwardIter
    adjacent_find(_ForwardIter __first, _ForwardIter __last)
    {




      if (__first == __last)
        return __last;
      _ForwardIter __next = __first;
      while(++__next != __last) {
        if (*__first == *__next)
          return __first;
        __first = __next;
      }
      return __last;
    }
# 358 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _BinaryPredicate>
    _ForwardIter
    adjacent_find(_ForwardIter __first, _ForwardIter __last,
                  _BinaryPredicate __binary_pred)
    {





      if (__first == __last)
        return __last;
      _ForwardIter __next = __first;
      while(++__next != __last) {
        if (__binary_pred(*__first, *__next))
          return __first;
        __first = __next;
      }
      return __last;
    }
# 387 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Tp>
    typename iterator_traits<_InputIter>::difference_type
    count(_InputIter __first, _InputIter __last, const _Tp& __value)
    {





      typename iterator_traits<_InputIter>::difference_type __n = 0;
      for ( ; __first != __last; ++__first)
        if (*__first == __value)
          ++__n;
      return __n;
    }
# 411 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Predicate>
    typename iterator_traits<_InputIter>::difference_type
    count_if(_InputIter __first, _InputIter __last, _Predicate __pred)
    {




      typename iterator_traits<_InputIter>::difference_type __n = 0;
      for ( ; __first != __last; ++__first)
        if (__pred(*__first))
          ++__n;
      return __n;
    }
# 450 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    _ForwardIter1
    search(_ForwardIter1 __first1, _ForwardIter1 __last1,
           _ForwardIter2 __first2, _ForwardIter2 __last2)
    {








      if (__first1 == __last1 || __first2 == __last2)
        return __first1;


      _ForwardIter2 __tmp(__first2);
      ++__tmp;
      if (__tmp == __last2)
        return find(__first1, __last1, *__first2);



      _ForwardIter2 __p1, __p;

      __p1 = __first2; ++__p1;

      _ForwardIter1 __current = __first1;

      while (__first1 != __last1) {
        __first1 = find(__first1, __last1, *__first2);
        if (__first1 == __last1)
          return __last1;

        __p = __p1;
        __current = __first1;
        if (++__current == __last1)
          return __last1;

        while (*__current == *__p) {
          if (++__p == __last2)
            return __first1;
          if (++__current == __last1)
            return __last1;
        }

        ++__first1;
      }
      return __first1;
    }
# 522 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2, typename
_BinaryPred>
    _ForwardIter1
    search(_ForwardIter1 __first1, _ForwardIter1 __last1,
           _ForwardIter2 __first2, _ForwardIter2 __last2,
           _BinaryPred __predicate)
    {








      if (__first1 == __last1 || __first2 == __last2)
        return __first1;


      _ForwardIter2 __tmp(__first2);
      ++__tmp;
      if (__tmp == __last2) {
        while (__first1 != __last1 && !__predicate(*__first1,
*__first2))
          ++__first1;
        return __first1;
      }



      _ForwardIter2 __p1, __p;

      __p1 = __first2; ++__p1;

      _ForwardIter1 __current = __first1;

      while (__first1 != __last1) {
        while (__first1 != __last1) {
          if (__predicate(*__first1, *__first2))
            break;
          ++__first1;
        }
        while (__first1 != __last1 && !__predicate(*__first1,
*__first2))
          ++__first1;
        if (__first1 == __last1)
          return __last1;

        __p = __p1;
        __current = __first1;
        if (++__current == __last1) return __last1;

        while (__predicate(*__current, *__p)) {
          if (++__p == __last2)
            return __first1;
          if (++__current == __last1)
            return __last1;
        }

        ++__first1;
      }
      return __first1;
    }
# 596 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Integer, typename _Tp>
    _ForwardIter
    search_n(_ForwardIter __first, _ForwardIter __last,
             _Integer __count, const _Tp& __val)
    {






      if (__count <= 0)
        return __first;
      else {
        __first = find(__first, __last, __val);
        while (__first != __last) {
          _Integer __n = __count - 1;
          _ForwardIter __i = __first;
          ++__i;
          while (__i != __last && __n != 0 && *__i == __val) {
            ++__i;
            --__n;
          }
          if (__n == 0)
            return __first;
          else
            __first = find(__i, __last, __val);
        }
        return __last;
      }
    }
# 643 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Integer, typename _Tp,
           typename _BinaryPred>
    _ForwardIter
    search_n(_ForwardIter __first, _ForwardIter __last,
             _Integer __count, const _Tp& __val,
             _BinaryPred __binary_pred)
    {





      if (__count <= 0)
        return __first;
      else {
        while (__first != __last) {
          if (__binary_pred(*__first, __val))
            break;
          ++__first;
        }
        while (__first != __last) {
          _Integer __n = __count - 1;
          _ForwardIter __i = __first;
          ++__i;
          while (__i != __last && __n != 0 && __binary_pred(*__i,
__val)) {
            ++__i;
            --__n;
          }
          if (__n == 0)
            return __first;
          else {
            while (__i != __last) {
              if (__binary_pred(*__i, __val))
                break;
              ++__i;
            }
            __first = __i;
          }
        }
        return __last;
      }
    }
# 697 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    _ForwardIter2
    swap_ranges(_ForwardIter1 __first1, _ForwardIter1 __last1,
                _ForwardIter2 __first2)
    {










      for ( ; __first1 != __last1; ++__first1, ++__first2)
        iter_swap(__first1, __first2);
      return __first2;
    }
# 732 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_UnaryOperation>
    _OutputIter
    transform(_InputIter __first, _InputIter __last,
              _OutputIter __result, _UnaryOperation __unary_op)
    {






      for ( ; __first != __last; ++__first, ++__result)
        *__result = __unary_op(*__first);
      return __result;
    }
# 765 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _BinaryOperation>
    _OutputIter
    transform(_InputIter1 __first1, _InputIter1 __last1,
              _InputIter2 __first2, _OutputIter __result,
              _BinaryOperation __binary_op)
    {







      for ( ; __first1 != __last1; ++__first1, ++__first2, ++__result)
        *__result = __binary_op(*__first1, *__first2);
      return __result;
    }
# 796 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    void
    replace(_ForwardIter __first, _ForwardIter __last,
            const _Tp& __old_value, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first)
        if (*__first == __old_value)
          *__first = __new_value;
    }
# 825 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate, typename _Tp>
    void
    replace_if(_ForwardIter __first, _ForwardIter __last,
               _Predicate __pred, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first)
        if (__pred(*__first))
          *__first = __new_value;
    }
# 856 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename _Tp>
    _OutputIter
    replace_copy(_InputIter __first, _InputIter __last,
                 _OutputIter __result,
                 const _Tp& __old_value, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first, ++__result)
        *__result = *__first == __old_value ? __new_value : *__first;
      return __result;
    }
# 888 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_Predicate,
           typename _Tp>
    _OutputIter
    replace_copy_if(_InputIter __first, _InputIter __last,
                    _OutputIter __result,
                    _Predicate __pred, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first, ++__result)
        *__result = __pred(*__first) ? __new_value : *__first;
      return __result;
    }
# 918 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Generator>
    void
    generate(_ForwardIter __first, _ForwardIter __last, _Generator
__gen)
    {





      for ( ; __first != __last; ++__first)
        *__first = __gen();
    }
# 942 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _OutputIter, typename _Size, typename _Generator>
    _OutputIter
    generate_n(_OutputIter __first, _Size __n, _Generator __gen)
    {





      for ( ; __n > 0; --__n, ++__first)
        *__first = __gen();
      return __first;
    }
# 969 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename _Tp>
    _OutputIter
    remove_copy(_InputIter __first, _InputIter __last,
                _OutputIter __result, const _Tp& __value)
    {







      for ( ; __first != __last; ++__first)
        if (!(*__first == __value)) {
          *__result = *__first;
          ++__result;
        }
      return __result;
    }
# 1003 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_Predicate>
    _OutputIter
    remove_copy_if(_InputIter __first, _InputIter __last,
                   _OutputIter __result, _Predicate __pred)
    {







      for ( ; __first != __last; ++__first)
        if (!__pred(*__first)) {
          *__result = *__first;
          ++__result;
        }
      return __result;
    }
# 1039 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    _ForwardIter
    remove(_ForwardIter __first, _ForwardIter __last,
           const _Tp& __value)
    {







      __first = find(__first, __last, __value);
      _ForwardIter __i = __first;
      return __first == __last ? __first
                               : remove_copy(++__i, __last, __first,
__value);
    }
# 1073 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate>
    _ForwardIter
    remove_if(_ForwardIter __first, _ForwardIter __last,
              _Predicate __pred)
    {





      __first = find_if(__first, __last, __pred);
      _ForwardIter __i = __first;
      return __first == __last ? __first
                               : remove_copy_if(++__i, __last, __first,
__pred);
    }







  template<typename _InputIter, typename _OutputIter>
    _OutputIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _OutputIter __result,
                  output_iterator_tag)
    {

      typename iterator_traits<_InputIter>::value_type __value =
*__first;
      *__result = __value;
      while (++__first != __last)
        if (!(__value == *__first)) {
          __value = *__first;
          *++__result = __value;
        }
      return ++__result;
    }







  template<typename _InputIter, typename _ForwardIter>
    _ForwardIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _ForwardIter __result,
                  forward_iterator_tag)
    {

      *__result = *__first;
      while (++__first != __last)
        if (!(*__result == *__first))
          *++__result = *__first;
      return ++__result;
    }
# 1145 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    unique_copy(_InputIter __first, _InputIter __last,
                _OutputIter __result)
    {







      typedef typename iterator_traits<_OutputIter>::iterator_category
_IterType;

      if (__first == __last) return __result;
      return __unique_copy(__first, __last, __result, _IterType());
    }
# 1170 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_BinaryPredicate>
    _OutputIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _OutputIter __result,
                  _BinaryPredicate __binary_pred,
                  output_iterator_tag)
    {





      typename iterator_traits<_InputIter>::value_type __value =
*__first;
      *__result = __value;
      while (++__first != __last)
        if (!__binary_pred(__value, *__first)) {
          __value = *__first;
          *++__result = __value;
        }
      return ++__result;
    }
# 1199 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _ForwardIter, typename
_BinaryPredicate>
    _ForwardIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _ForwardIter __result,
                  _BinaryPredicate __binary_pred,
                  forward_iterator_tag)
    {





      *__result = *__first;
      while (++__first != __last)
        if (!__binary_pred(*__result, *__first)) *++__result = *__first;
      return ++__result;
    }
# 1232 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_BinaryPredicate>
    inline _OutputIter
    unique_copy(_InputIter __first, _InputIter __last,
                _OutputIter __result,
                _BinaryPredicate __binary_pred)
    {





      typedef typename iterator_traits<_OutputIter>::iterator_category
_IterType;

      if (__first == __last) return __result;
      return __unique_copy(__first, __last,
__result, __binary_pred, _IterType());
    }
# 1263 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter>
    _ForwardIter
    unique(_ForwardIter __first, _ForwardIter __last)
    {





          __first = adjacent_find(__first, __last);
          return unique_copy(__first, __last, __first);
    }
# 1290 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _BinaryPredicate>
    _ForwardIter
    unique(_ForwardIter __first, _ForwardIter __last,
           _BinaryPredicate __binary_pred)
    {






      __first = adjacent_find(__first, __last, __binary_pred);
      return unique_copy(__first, __last, __first, __binary_pred);
    }







  template<typename _BidirectionalIter>
    void
    __reverse(_BidirectionalIter __first, _BidirectionalIter __last,
                          bidirectional_iterator_tag)
    {
          while (true)
            if (__first == __last || __first == --__last)
                  return;
            else
                  iter_swap(__first++, __last);
    }







  template<typename _RandomAccessIter>
    void
    __reverse(_RandomAccessIter __first, _RandomAccessIter __last,
                          random_access_iterator_tag)
    {
          while (__first < __last)
            iter_swap(__first++, --__last);
    }
# 1349 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter>
    inline void
    reverse(_BidirectionalIter __first, _BidirectionalIter __last)
    {



          __reverse(__first, __last, __iterator_category(__first));
    }
# 1374 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter, typename _OutputIter>
    _OutputIter
    reverse_copy(_BidirectionalIter __first, _BidirectionalIter __last,
                             _OutputIter __result)
    {





      while (__first != __last) {
        --__last;
        *__result = *__last;
        ++__result;
      }
      return __result;
    }
# 1399 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _EuclideanRingElement>
    _EuclideanRingElement
    __gcd(_EuclideanRingElement __m, _EuclideanRingElement __n)
    {
      while (__n != 0) {
        _EuclideanRingElement __t = __m % __n;
        __m = __n;
        __n = __t;
      }
      return __m;
    }






  template<typename _ForwardIter>
    void
    __rotate(_ForwardIter __first,
             _ForwardIter __middle,
             _ForwardIter __last,
              forward_iterator_tag)
    {
      if ((__first == __middle) || (__last == __middle))
        return;

      _ForwardIter __first2 = __middle;
      do {
        swap(*__first++, *__first2++);
        if (__first == __middle)
          __middle = __first2;
      } while (__first2 != __last);

      __first2 = __middle;

      while (__first2 != __last) {
        swap(*__first++, *__first2++);
        if (__first == __middle)
          __middle = __first2;
        else if (__first2 == __last)
          __first2 = __middle;
      }
    }






  template<typename _BidirectionalIter>
    void
    __rotate(_BidirectionalIter __first,
             _BidirectionalIter __middle,
             _BidirectionalIter __last,
              bidirectional_iterator_tag)
    {




      if ((__first == __middle) || (__last == __middle))
        return;

      __reverse(__first, __middle, bidirectional_iterator_tag());
      __reverse(__middle, __last, bidirectional_iterator_tag());

      while (__first != __middle && __middle != __last)
        swap (*__first++, *--__last);

      if (__first == __middle) {
        __reverse(__middle, __last, bidirectional_iterator_tag());
      }
      else {
        __reverse(__first, __middle, bidirectional_iterator_tag());
      }
    }






  template<typename _RandomAccessIter>
    void
    __rotate(_RandomAccessIter __first,
             _RandomAccessIter __middle,
             _RandomAccessIter __last,
             random_access_iterator_tag)
    {




      if ((__first == __middle) || (__last == __middle))
        return;

      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _Distance;
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      _Distance __n = __last - __first;
      _Distance __k = __middle - __first;
      _Distance __l = __n - __k;

      if (__k == __l) {
        swap_ranges(__first, __middle, __middle);
        return;
      }

      _Distance __d = __gcd(__n, __k);

      for (_Distance __i = 0; __i < __d; __i++) {
        _ValueType __tmp = *__first;
        _RandomAccessIter __p = __first;

        if (__k < __l) {
          for (_Distance __j = 0; __j < __l/__d; __j++) {
            if (__p > __first + __l) {
              *__p = *(__p - __l);
              __p -= __l;
            }

            *__p = *(__p + __k);
            __p += __k;
          }
        }

        else {
          for (_Distance __j = 0; __j < __k/__d - 1; __j ++) {
            if (__p < __last - __k) {
              *__p = *(__p + __k);
              __p += __k;
            }

            *__p = * (__p - __l);
            __p -= __l;
          }
        }

        *__p = __tmp;
        ++__first;
      }
    }
# 1561 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter>
    inline void
    rotate(_ForwardIter __first, _ForwardIter __middle, _ForwardIter
__last)
    {



      typedef typename iterator_traits<_ForwardIter>::iterator_category
_IterType;
      __rotate(__first, __middle, __last, _IterType());
    }
# 1589 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _OutputIter>
    _OutputIter
    rotate_copy(_ForwardIter __first, _ForwardIter __middle,
                _ForwardIter __last, _OutputIter __result)
    {





      return copy(__first, __middle, copy(__middle, __last, __result));
    }
# 1612 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _Distance>
    inline _Distance
    __random_number(_Distance __n)
    {

      return lrand48() % __n;



    }
# 1634 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    inline void
    random_shuffle(_RandomAccessIter __first, _RandomAccessIter __last)
    {




      if (__first == __last) return;
      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
        iter_swap(__i, __first + __random_number((__i - __first) + 1));
    }
# 1660 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _RandomNumberGenerator>
    void
    random_shuffle(_RandomAccessIter __first, _RandomAccessIter __last,
                   _RandomNumberGenerator& __rand)
    {




      if (__first == __last) return;
      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
        iter_swap(__i, __first + __rand((__i - __first) + 1));
    }







  template<typename _ForwardIter, typename _Predicate>
    _ForwardIter
    __partition(_ForwardIter __first, _ForwardIter __last,
                _Predicate __pred,
                forward_iterator_tag)
    {
      if (__first == __last) return __first;

      while (__pred(*__first))
        if (++__first == __last) return __first;

      _ForwardIter __next = __first;

      while (++__next != __last)
        if (__pred(*__next)) {
          swap(*__first, *__next);
          ++__first;
        }

      return __first;
    }






  template<typename _BidirectionalIter, typename _Predicate>
    _BidirectionalIter
    __partition(_BidirectionalIter __first, _BidirectionalIter __last,
                _Predicate __pred,
                bidirectional_iterator_tag)
    {
      while (true) {
        while (true)
          if (__first == __last)
            return __first;
          else if (__pred(*__first))
            ++__first;
          else
            break;
        --__last;
        while (true)
          if (__first == __last)
            return __first;
          else if (!__pred(*__last))
            --__last;
          else
            break;
        iter_swap(__first, __last);
        ++__first;
      }
    }
# 1748 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate>
    inline _ForwardIter
    partition(_ForwardIter __first, _ForwardIter __last,
              _Predicate __pred)
    {





      return __partition(__first, __last, __pred,
__iterator_category(__first));
    }







  template<typename _ForwardIter, typename _Predicate, typename
_Distance>
    _ForwardIter
    __inplace_stable_partition(_ForwardIter __first, _ForwardIter
__last,
                               _Predicate __pred, _Distance __len)
    {
      if (__len == 1)
        return __pred(*__first) ? __last : __first;
      _ForwardIter __middle = __first;
      advance(__middle, __len / 2);
      _ForwardIter __begin = __inplace_stable_partition(__first,
__middle,
                                                        __pred,
                                                        __len / 2);
      _ForwardIter __end = __inplace_stable_partition(__middle, __last,
                                                      __pred,
                                                      __len - __len /
2);
      rotate(__begin, __middle, __end);
      advance(__begin, distance(__middle, __end));
      return __begin;
    }






  template<typename _ForwardIter, typename _Pointer, typename
_Predicate,
           typename _Distance>
    _ForwardIter
    __stable_partition_adaptive(_ForwardIter __first, _ForwardIter
__last,
                                _Predicate __pred, _Distance __len,
                                _Pointer __buffer,
                                _Distance __buffer_size)
    {
      if (__len <= __buffer_size) {
        _ForwardIter __result1 = __first;
        _Pointer __result2 = __buffer;
        for ( ; __first != __last ; ++__first)
          if (__pred(*__first)) {
            *__result1 = *__first;
            ++__result1;
          }
          else {
            *__result2 = *__first;
            ++__result2;
          }
        copy(__buffer, __result2, __result1);
        return __result1;
      }
      else {
        _ForwardIter __middle = __first;
        advance(__middle, __len / 2);
        _ForwardIter __begin = __stable_partition_adaptive(__first,
__middle,
                                                           __pred,
                                                           __len / 2,
                                                           __buffer,
__buffer_size);
        _ForwardIter __end = __stable_partition_adaptive( __middle,
__last,
                                                          __pred,
                                                          __len - __len
/ 2,
                                                          __buffer,
__buffer_size);
        rotate(__begin, __middle, __end);
        advance(__begin, distance(__middle, __end));
        return __begin;
      }
    }
# 1848 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate>
    _ForwardIter
    stable_partition(_ForwardIter __first, _ForwardIter __last,
                     _Predicate __pred)
    {





      if (__first == __last)
        return __first;
      else
      {
        typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
        typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;

        _Temporary_buffer<_ForwardIter, _ValueType> __buf(__first,
__last);
        if (__buf.size() > 0)
          return __stable_partition_adaptive(__first, __last, __pred,

_DistanceType(__buf.requested_size()),
                                             __buf.begin(),
__buf.size());
        else
          return __inplace_stable_partition(__first, __last, __pred,

_DistanceType(__buf.requested_size()));
      }
    }






  template<typename _RandomAccessIter, typename _Tp>
    _RandomAccessIter
    __unguarded_partition(_RandomAccessIter __first, _RandomAccessIter
__last,
                          _Tp __pivot)
    {
      while (true) {
        while (*__first < __pivot)
          ++__first;
        --__last;
        while (__pivot < *__last)
          --__last;
        if (!(__first < __last))
          return __first;
        iter_swap(__first, __last);
        ++__first;
      }
    }






  template<typename _RandomAccessIter, typename _Tp, typename _Compare>
    _RandomAccessIter
    __unguarded_partition(_RandomAccessIter __first, _RandomAccessIter
__last,
                          _Tp __pivot, _Compare __comp)
    {
      while (true) {
        while (__comp(*__first, __pivot))
          ++__first;
        --__last;
        while (__comp(__pivot, *__last))
          --__last;
        if (!(__first < __last))
          return __first;
        iter_swap(__first, __last);
        ++__first;
      }
    }
# 1929 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  enum { _M_threshold = 16 };






  template<typename _RandomAccessIter, typename _Tp>
    void
    __unguarded_linear_insert(_RandomAccessIter __last, _Tp __val)
    {
      _RandomAccessIter __next = __last;
      --__next;
      while (__val < *__next) {
        *__last = *__next;
        __last = __next;
        --__next;
      }
      *__last = __val;
    }






  template<typename _RandomAccessIter, typename _Tp, typename _Compare>
    void
    __unguarded_linear_insert(_RandomAccessIter __last, _Tp __val,
_Compare __comp)
    {
      _RandomAccessIter __next = __last;
      --__next;
      while (__comp(__val, *__next)) {
        *__last = *__next;
        __last = __next;
        --__next;
      }
      *__last = __val;
    }






  template<typename _RandomAccessIter>
    void
    __insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last)
    {
      if (__first == __last) return;

      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
      {
        typename iterator_traits<_RandomAccessIter>::value_type __val =
*__i;
        if (__val < *__first) {
          copy_backward(__first, __i, __i + 1);
          *__first = __val;
        }
        else
          __unguarded_linear_insert(__i, __val);
      }
    }






  template<typename _RandomAccessIter, typename _Compare>
    void
    __insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                     _Compare __comp)
    {
      if (__first == __last) return;

      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
      {
        typename iterator_traits<_RandomAccessIter>::value_type __val =
*__i;
        if (__comp(__val, *__first)) {
          copy_backward(__first, __i, __i + 1);
          *__first = __val;
        }
        else
          __unguarded_linear_insert(__i, __val, __comp);
      }
    }






  template<typename _RandomAccessIter>
    inline void
    __unguarded_insertion_sort(_RandomAccessIter __first,
_RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      for (_RandomAccessIter __i = __first; __i != __last; ++__i)
        __unguarded_linear_insert(__i, _ValueType(*__i));
    }






  template<typename _RandomAccessIter, typename _Compare>
    inline void
    __unguarded_insertion_sort(_RandomAccessIter __first,
_RandomAccessIter __last,
                               _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      for (_RandomAccessIter __i = __first; __i != __last; ++__i)
        __unguarded_linear_insert(__i, _ValueType(*__i), __comp);
    }






  template<typename _RandomAccessIter>
    void
    __final_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last)
    {
      if (__last - __first > _M_threshold) {
        __insertion_sort(__first, __first + _M_threshold);
        __unguarded_insertion_sort(__first + _M_threshold, __last);
      }
      else
        __insertion_sort(__first, __last);
    }






  template<typename _RandomAccessIter, typename _Compare>
    void
    __final_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Compare __comp)
    {
      if (__last - __first > _M_threshold) {
        __insertion_sort(__first, __first + _M_threshold, __comp);
        __unguarded_insertion_sort(__first + _M_threshold, __last,
__comp);
      }
      else
        __insertion_sort(__first, __last, __comp);
    }






  template<typename _Size>
    inline _Size
    __lg(_Size __n)
    {
      _Size __k;
      for (__k = 0; __n != 1; __n >>= 1) ++__k;
      return __k;
    }






  template<typename _RandomAccessIter, typename _Size>
    void
    __introsort_loop(_RandomAccessIter __first, _RandomAccessIter
__last,
                     _Size __depth_limit)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      while (__last - __first > _M_threshold) {
        if (__depth_limit == 0) {
          partial_sort(__first, __last, __last);
          return;
        }
        --__depth_limit;
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1))));
        __introsort_loop(__cut, __last, __depth_limit);
        __last = __cut;
      }
    }






  template<typename _RandomAccessIter, typename _Size, typename
_Compare>
    void
    __introsort_loop(_RandomAccessIter __first, _RandomAccessIter
__last,
                     _Size __depth_limit, _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      while (__last - __first > _M_threshold) {
        if (__depth_limit == 0) {
          partial_sort(__first, __last, __last, __comp);
          return;
        }
        --__depth_limit;
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1),
__comp)),
           __comp);
        __introsort_loop(__cut, __last, __depth_limit, __comp);
        __last = __cut;
      }
    }
# 2166 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    inline void
    sort(_RandomAccessIter __first, _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      if (__first != __last) {
        __introsort_loop(__first, __last, __lg(__last - __first) * 2);
        __final_insertion_sort(__first, __last);
      }
    }
# 2197 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    inline void
    sort(_RandomAccessIter __first, _RandomAccessIter __last, _Compare
__comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      if (__first != __last) {
        __introsort_loop(__first, __last, __lg(__last - __first) * 2,
__comp);
        __final_insertion_sort(__first, __last, __comp);
      }
    }







  template<typename _RandomAccessIter>
    void
    __inplace_stable_sort(_RandomAccessIter __first, _RandomAccessIter
__last)
    {
      if (__last - __first < 15) {
        __insertion_sort(__first, __last);
        return;
      }
      _RandomAccessIter __middle = __first + (__last - __first) / 2;
      __inplace_stable_sort(__first, __middle);
      __inplace_stable_sort(__middle, __last);
      __merge_without_buffer(__first, __middle, __last,
                             __middle - __first,
                             __last - __middle);
    }






  template<typename _RandomAccessIter, typename _Compare>
    void
    __inplace_stable_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                          _Compare __comp)
    {
      if (__last - __first < 15) {
        __insertion_sort(__first, __last, __comp);
        return;
      }
      _RandomAccessIter __middle = __first + (__last - __first) / 2;
      __inplace_stable_sort(__first, __middle, __comp);
      __inplace_stable_sort(__middle, __last, __comp);
      __merge_without_buffer(__first, __middle, __last,
                             __middle - __first,
                             __last - __middle,
                             __comp);
    }

  template<typename _RandomAccessIter1, typename _RandomAccessIter2,
           typename _Distance>
    void
    __merge_sort_loop(_RandomAccessIter1 __first, _RandomAccessIter1
__last,
                      _RandomAccessIter2 __result, _Distance
__step_size)
    {
      _Distance __two_step = 2 * __step_size;

      while (__last - __first >= __two_step) {
        __result = merge(__first, __first + __step_size,
                         __first + __step_size, __first + __two_step,
                         __result);
        __first += __two_step;
      }

      __step_size = min(_Distance(__last - __first), __step_size);
      merge(__first, __first + __step_size, __first + __step_size,
__last,
            __result);
    }

  template<typename _RandomAccessIter1, typename _RandomAccessIter2,
           typename _Distance, typename _Compare>
    void
    __merge_sort_loop(_RandomAccessIter1 __first, _RandomAccessIter1
__last,
                      _RandomAccessIter2 __result, _Distance
__step_size,
                      _Compare __comp)
    {
      _Distance __two_step = 2 * __step_size;

      while (__last - __first >= __two_step) {
        __result = merge(__first, __first + __step_size,
                         __first + __step_size, __first + __two_step,
                         __result,
                         __comp);
        __first += __two_step;
      }
      __step_size = min(_Distance(__last - __first), __step_size);

      merge(__first, __first + __step_size,
            __first + __step_size, __last,
            __result,
            __comp);
    }

  enum { _M_chunk_size = 7 };

  template<typename _RandomAccessIter, typename _Distance>
    void
    __chunk_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Distance __chunk_size)
    {
      while (__last - __first >= __chunk_size) {
        __insertion_sort(__first, __first + __chunk_size);
        __first += __chunk_size;
      }
      __insertion_sort(__first, __last);
    }

  template<typename _RandomAccessIter, typename _Distance, typename
_Compare>
    void
    __chunk_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Distance __chunk_size, _Compare __comp)
    {
      while (__last - __first >= __chunk_size) {
        __insertion_sort(__first, __first + __chunk_size, __comp);
        __first += __chunk_size;
      }
      __insertion_sort(__first, __last, __comp);
    }

  template<typename _RandomAccessIter, typename _Pointer>
    void
    __merge_sort_with_buffer(_RandomAccessIter __first,
_RandomAccessIter __last,
                             _Pointer __buffer)
    {
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _Distance;

      _Distance __len = __last - __first;
      _Pointer __buffer_last = __buffer + __len;

      _Distance __step_size = _M_chunk_size;
      __chunk_insertion_sort(__first, __last, __step_size);

      while (__step_size < __len) {
        __merge_sort_loop(__first, __last, __buffer, __step_size);
        __step_size *= 2;
        __merge_sort_loop(__buffer, __buffer_last, __first,
__step_size);
        __step_size *= 2;
      }
    }

  template<typename _RandomAccessIter, typename _Pointer, typename
_Compare>
    void
    __merge_sort_with_buffer(_RandomAccessIter __first,
_RandomAccessIter __last,
                             _Pointer __buffer, _Compare __comp)
    {
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _Distance;

      _Distance __len = __last - __first;
      _Pointer __buffer_last = __buffer + __len;

      _Distance __step_size = _M_chunk_size;
      __chunk_insertion_sort(__first, __last, __step_size, __comp);

      while (__step_size < __len) {
        __merge_sort_loop(__first, __last, __buffer, __step_size,
__comp);
        __step_size *= 2;
        __merge_sort_loop(__buffer, __buffer_last, __first, __step_size,
__comp);
        __step_size *= 2;
      }
    }

  template<typename _RandomAccessIter, typename _Pointer, typename
_Distance>
    void
    __stable_sort_adaptive(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Pointer __buffer, _Distance __buffer_size)
    {
      _Distance __len = (__last - __first + 1) / 2;
      _RandomAccessIter __middle = __first + __len;
      if (__len > __buffer_size) {
        __stable_sort_adaptive(__first, __middle, __buffer,
__buffer_size);
        __stable_sort_adaptive(__middle, __last, __buffer,
__buffer_size);
      }
      else {
        __merge_sort_with_buffer(__first, __middle, __buffer);
        __merge_sort_with_buffer(__middle, __last, __buffer);
      }
      __merge_adaptive(__first, __middle, __last, _Distance(__middle -
__first),
                       _Distance(__last - __middle), __buffer,
__buffer_size);
    }

  template<typename _RandomAccessIter, typename _Pointer, typename
_Distance,
           typename _Compare>
    void
    __stable_sort_adaptive(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Pointer __buffer, _Distance __buffer_size,
                           _Compare __comp)
    {
      _Distance __len = (__last - __first + 1) / 2;
      _RandomAccessIter __middle = __first + __len;
      if (__len > __buffer_size) {
        __stable_sort_adaptive(__first, __middle, __buffer,
__buffer_size,
                               __comp);
        __stable_sort_adaptive(__middle, __last, __buffer,
__buffer_size,
                               __comp);
      }
      else {
        __merge_sort_with_buffer(__first, __middle, __buffer, __comp);
        __merge_sort_with_buffer(__middle, __last, __buffer, __comp);
      }
      __merge_adaptive(__first, __middle, __last, _Distance(__middle -
__first),
                       _Distance(__last - __middle), __buffer,
__buffer_size,
                       __comp);
    }
# 2430 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    inline void
    stable_sort(_RandomAccessIter __first, _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;






      _Temporary_buffer<_RandomAccessIter, _ValueType> buf(__first,
__last);
      if (buf.begin() == 0)
        __inplace_stable_sort(__first, __last);
      else
        __stable_sort_adaptive(__first, __last, buf.begin(),
_DistanceType(buf.size()));
    }
# 2466 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    inline void
    stable_sort(_RandomAccessIter __first, _RandomAccessIter __last,
_Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;







      _Temporary_buffer<_RandomAccessIter, _ValueType> buf(__first,
__last);
      if (buf.begin() == 0)
        __inplace_stable_sort(__first, __last, __comp);
      else
        __stable_sort_adaptive(__first, __last, buf.begin(),
_DistanceType(buf.size()),
                               __comp);
    }
# 2502 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    void
    partial_sort(_RandomAccessIter __first,
                 _RandomAccessIter __middle,
                 _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      make_heap(__first, __middle);
      for (_RandomAccessIter __i = __middle; __i < __last; ++__i)
        if (*__i < *__first)
          __pop_heap(__first, __middle, __i, _ValueType(*__i));
      sort_heap(__first, __middle);
    }
# 2540 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    void
    partial_sort(_RandomAccessIter __first,
                 _RandomAccessIter __middle,
                 _RandomAccessIter __last,
                 _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;







      make_heap(__first, __middle, __comp);
      for (_RandomAccessIter __i = __middle; __i < __last; ++__i)
        if (__comp(*__i, *__first))
          __pop_heap(__first, __middle, __i, _ValueType(*__i), __comp);
      sort_heap(__first, __middle, __comp);
    }
# 2579 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _RandomAccessIter>
    _RandomAccessIter
    partial_sort_copy(_InputIter __first, _InputIter __last,
                      _RandomAccessIter __result_first,
                      _RandomAccessIter __result_last)
    {
      typedef typename iterator_traits<_InputIter>::value_type
_InputValueType;
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_OutputValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;







      if (__result_first == __result_last) return __result_last;
      _RandomAccessIter __result_real_last = __result_first;
      while(__first != __last && __result_real_last != __result_last) {
        *__result_real_last = *__first;
        ++__result_real_last;
        ++__first;
      }
      make_heap(__result_first, __result_real_last);
      while (__first != __last) {
        if (*__first < *__result_first)
          __adjust_heap(__result_first, _DistanceType(0),
                        _DistanceType(__result_real_last -
__result_first),
                        _InputValueType(*__first));
        ++__first;
      }
      sort_heap(__result_first, __result_real_last);
      return __result_real_last;
    }
# 2633 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _RandomAccessIter, typename
_Compare>
    _RandomAccessIter
    partial_sort_copy(_InputIter __first, _InputIter __last,
                      _RandomAccessIter __result_first,
                      _RandomAccessIter __result_last,
                      _Compare __comp)
    {
      typedef typename iterator_traits<_InputIter>::value_type
_InputValueType;
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_OutputValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;








      if (__result_first == __result_last) return __result_last;
      _RandomAccessIter __result_real_last = __result_first;
      while(__first != __last && __result_real_last != __result_last) {
        *__result_real_last = *__first;
        ++__result_real_last;
        ++__first;
      }
      make_heap(__result_first, __result_real_last, __comp);
      while (__first != __last) {
        if (__comp(*__first, *__result_first))
          __adjust_heap(__result_first, _DistanceType(0),
                        _DistanceType(__result_real_last -
__result_first),
                        _InputValueType(*__first),
                        __comp);
        ++__first;
      }
      sort_heap(__result_first, __result_real_last, __comp);
      return __result_real_last;
    }
# 2686 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    void
    nth_element(_RandomAccessIter __first,
                _RandomAccessIter __nth,
                _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;





      while (__last - __first > 3) {
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1))));
        if (__cut <= __nth)
          __first = __cut;
        else
          __last = __cut;
      }
      __insertion_sort(__first, __last);
    }
# 2728 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    void
    nth_element(_RandomAccessIter __first,
                _RandomAccessIter __nth,
                _RandomAccessIter __last,
                            _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      while (__last - __first > 3) {
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1),
                                                    __comp)),
                                __comp);
        if (__cut <= __nth)
          __first = __cut;
        else
          __last = __cut;
      }
      __insertion_sort(__first, __last, __comp);
    }
# 2768 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    _ForwardIter
    lower_bound(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;










      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (*__middle < __val) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else
          __len = __half;
      }
      return __first;
    }
# 2816 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    _ForwardIter
    lower_bound(_ForwardIter __first, _ForwardIter __last,
                const _Tp& __val, _Compare __comp)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;





      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__comp(*__middle, __val)) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else
          __len = __half;
      }
      return __first;
    }
# 2856 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    _ForwardIter
    upper_bound(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;







      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__val < *__middle)
          __len = __half;
        else {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
      }
      return __first;
    }
# 2901 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    _ForwardIter
    upper_bound(_ForwardIter __first, _ForwardIter __last,
                const _Tp& __val, _Compare __comp)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;





      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__comp(__val, *__middle))
          __len = __half;
        else {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
      }
      return __first;
    }
# 2948 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    pair<_ForwardIter, _ForwardIter>
    equal_range(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;







      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle, __left, __right;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (*__middle < __val) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else if (__val < *__middle)
          __len = __half;
        else {
          __left = lower_bound(__first, __middle, __val);
          advance(__first, __len);
          __right = upper_bound(++__middle, __first, __val);
          return pair<_ForwardIter, _ForwardIter>(__left, __right);
        }
      }
      return pair<_ForwardIter, _ForwardIter>(__first, __first);
    }
# 3003 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    pair<_ForwardIter, _ForwardIter>
    equal_range(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val,
                _Compare __comp)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;






      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle, __left, __right;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__comp(*__middle, __val)) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else if (__comp(__val, *__middle))
          __len = __half;
        else {
          __left = lower_bound(__first, __middle, __val, __comp);
          advance(__first, __len);
          __right = upper_bound(++__middle, __first, __val, __comp);
          return pair<_ForwardIter, _ForwardIter>(__left, __right);
        }
      }
      return pair<_ForwardIter, _ForwardIter>(__first, __first);
    }
# 3052 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    bool
    binary_search(_ForwardIter __first, _ForwardIter __last,
                  const _Tp& __val)
    {







      _ForwardIter __i = lower_bound(__first, __last, __val);
      return __i != __last && !(__val < *__i);
    }
# 3083 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    bool
    binary_search(_ForwardIter __first, _ForwardIter __last,
                  const _Tp& __val, _Compare __comp)
    {







      _ForwardIter __i = lower_bound(__first, __last, __val, __comp);
      return __i != __last && !__comp(__val, *__i);
    }
# 3115 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    merge(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2, _InputIter2 __last2,
          _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2) {
        if (*__first2 < *__first1) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }
# 3166 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    merge(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2, _InputIter2 __last2,
          _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2) {
        if (__comp(*__first2, *__first1)) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }






  template<typename _BidirectionalIter, typename _Distance>
    void
    __merge_without_buffer(_BidirectionalIter __first,
                           _BidirectionalIter __middle,
                           _BidirectionalIter __last,
                           _Distance __len1, _Distance __len2)
    {
      if (__len1 == 0 || __len2 == 0)
        return;
      if (__len1 + __len2 == 2) {
        if (*__middle < *__first)
              iter_swap(__first, __middle);
        return;
      }
      _BidirectionalIter __first_cut = __first;
      _BidirectionalIter __second_cut = __middle;
      _Distance __len11 = 0;
      _Distance __len22 = 0;
      if (__len1 > __len2) {
        __len11 = __len1 / 2;
        advance(__first_cut, __len11);
        __second_cut = lower_bound(__middle, __last, *__first_cut);
        __len22 = distance(__middle, __second_cut);
      }
      else {
        __len22 = __len2 / 2;
        advance(__second_cut, __len22);
        __first_cut = upper_bound(__first, __middle, *__second_cut);
        __len11 = distance(__first, __first_cut);
      }
      rotate(__first_cut, __middle, __second_cut);
      _BidirectionalIter __new_middle = __first_cut;
      advance(__new_middle, distance(__middle, __second_cut));
      __merge_without_buffer(__first, __first_cut, __new_middle,
                             __len11, __len22);
      __merge_without_buffer(__new_middle, __second_cut, __last,
                             __len1 - __len11, __len2 - __len22);
    }






  template<typename _BidirectionalIter, typename _Distance, typename
_Compare>
    void
    __merge_without_buffer(_BidirectionalIter __first,
                           _BidirectionalIter __middle,
                           _BidirectionalIter __last,
                           _Distance __len1, _Distance __len2,
                           _Compare __comp)
    {
      if (__len1 == 0 || __len2 == 0)
        return;
      if (__len1 + __len2 == 2) {
        if (__comp(*__middle, *__first))
              iter_swap(__first, __middle);
        return;
      }
      _BidirectionalIter __first_cut = __first;
      _BidirectionalIter __second_cut = __middle;
      _Distance __len11 = 0;
      _Distance __len22 = 0;
      if (__len1 > __len2) {
        __len11 = __len1 / 2;
        advance(__first_cut, __len11);
        __second_cut = lower_bound(__middle, __last, *__first_cut,
__comp);
        __len22 = distance(__middle, __second_cut);
      }
      else {
        __len22 = __len2 / 2;
        advance(__second_cut, __len22);
        __first_cut = upper_bound(__first, __middle, *__second_cut,
__comp);
        __len11 = distance(__first, __first_cut);
      }
      rotate(__first_cut, __middle, __second_cut);
      _BidirectionalIter __new_middle = __first_cut;
      advance(__new_middle, distance(__middle, __second_cut));
      __merge_without_buffer(__first, __first_cut, __new_middle,
                             __len11, __len22, __comp);
      __merge_without_buffer(__new_middle, __second_cut, __last,
                             __len1 - __len11, __len2 - __len22,
__comp);
    }






  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _Distance>
    _BidirectionalIter1
    __rotate_adaptive(_BidirectionalIter1 __first,
                      _BidirectionalIter1 __middle,
                      _BidirectionalIter1 __last,
                      _Distance __len1, _Distance __len2,
                      _BidirectionalIter2 __buffer,
                      _Distance __buffer_size)
    {
      _BidirectionalIter2 __buffer_end;
      if (__len1 > __len2 && __len2 <= __buffer_size) {
        __buffer_end = copy(__middle, __last, __buffer);
        copy_backward(__first, __middle, __last);
        return copy(__buffer, __buffer_end, __first);
      }
      else if (__len1 <= __buffer_size) {
        __buffer_end = copy(__first, __middle, __buffer);
        copy(__middle, __last, __first);
        return copy_backward(__buffer, __buffer_end, __last);
      }
      else {
        rotate(__first, __middle, __last);
        advance(__first, distance(__middle, __last));
        return __first;
      }
    }






  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BidirectionalIter3>
    _BidirectionalIter3
    __merge_backward(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
                     _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
                     _BidirectionalIter3 __result)
    {
      if (__first1 == __last1)
        return copy_backward(__first2, __last2, __result);
      if (__first2 == __last2)
        return copy_backward(__first1, __last1, __result);
      --__last1;
      --__last2;
      while (true) {
        if (*__last2 < *__last1) {
          *--__result = *__last1;
          if (__first1 == __last1)
            return copy_backward(__first2, ++__last2, __result);
          --__last1;
        }
        else {
          *--__result = *__last2;
          if (__first2 == __last2)
            return copy_backward(__first1, ++__last1, __result);
          --__last2;
        }
      }
    }






  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BidirectionalIter3, typename _Compare>
    _BidirectionalIter3
    __merge_backward(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
                     _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
                     _BidirectionalIter3 __result,
                     _Compare __comp)
    {
      if (__first1 == __last1)
        return copy_backward(__first2, __last2, __result);
      if (__first2 == __last2)
        return copy_backward(__first1, __last1, __result);
      --__last1;
      --__last2;
      while (true) {
        if (__comp(*__last2, *__last1)) {
          *--__result = *__last1;
          if (__first1 == __last1)
            return copy_backward(__first2, ++__last2, __result);
          --__last1;
        }
        else {
          *--__result = *__last2;
          if (__first2 == __last2)
            return copy_backward(__first1, ++__last1, __result);
          --__last2;
        }
      }
    }






  template<typename _BidirectionalIter, typename _Distance, typename
_Pointer>
    void
    __merge_adaptive(_BidirectionalIter __first,
                     _BidirectionalIter __middle,
                     _BidirectionalIter __last,
                     _Distance __len1, _Distance __len2,
                     _Pointer __buffer, _Distance __buffer_size)
    {
          if (__len1 <= __len2 && __len1 <= __buffer_size) {
            _Pointer __buffer_end = copy(__first, __middle, __buffer);
            merge(__buffer, __buffer_end, __middle, __last, __first);
          }
          else if (__len2 <= __buffer_size) {
            _Pointer __buffer_end = copy(__middle, __last, __buffer);
            __merge_backward(__first, __middle, __buffer, __buffer_end,
__last);
          }
          else {
            _BidirectionalIter __first_cut = __first;
            _BidirectionalIter __second_cut = __middle;
            _Distance __len11 = 0;
            _Distance __len22 = 0;
            if (__len1 > __len2) {
                  __len11 = __len1 / 2;
                  advance(__first_cut, __len11);
                  __second_cut = lower_bound(__middle, __last,
*__first_cut);
                  __len22 = distance(__middle, __second_cut);
            }
            else {
                  __len22 = __len2 / 2;
                  advance(__second_cut, __len22);
                  __first_cut = upper_bound(__first, __middle,
*__second_cut);
                  __len11 = distance(__first, __first_cut);
            }
            _BidirectionalIter __new_middle =
                  __rotate_adaptive(__first_cut, __middle, __second_cut,
                                    __len1 - __len11, __len22, __buffer,
                                    __buffer_size);
            __merge_adaptive(__first, __first_cut, __new_middle,
__len11,
                             __len22, __buffer, __buffer_size);
            __merge_adaptive(__new_middle, __second_cut, __last, __len1
- __len11,
                             __len2 - __len22, __buffer, __buffer_size);
          }
    }






  template<typename _BidirectionalIter, typename _Distance, typename
_Pointer,
           typename _Compare>
    void
    __merge_adaptive(_BidirectionalIter __first,
                     _BidirectionalIter __middle,
                     _BidirectionalIter __last,
                     _Distance __len1, _Distance __len2,
                     _Pointer __buffer, _Distance __buffer_size,
                     _Compare __comp)
    {
          if (__len1 <= __len2 && __len1 <= __buffer_size) {
            _Pointer __buffer_end = copy(__first, __middle, __buffer);
            merge(__buffer, __buffer_end, __middle, __last, __first,
__comp);
          }
          else if (__len2 <= __buffer_size) {
            _Pointer __buffer_end = copy(__middle, __last, __buffer);
            __merge_backward(__first, __middle, __buffer, __buffer_end,
__last,
                                             __comp);
          }
          else {
            _BidirectionalIter __first_cut = __first;
            _BidirectionalIter __second_cut = __middle;
            _Distance __len11 = 0;
            _Distance __len22 = 0;
            if (__len1 > __len2) {
                  __len11 = __len1 / 2;
                  advance(__first_cut, __len11);
                  __second_cut = lower_bound(__middle, __last,
*__first_cut, __comp);
                  __len22 = distance(__middle, __second_cut);
            }
            else {
                  __len22 = __len2 / 2;
                  advance(__second_cut, __len22);
                  __first_cut = upper_bound(__first, __middle,
*__second_cut, __comp);
                  __len11 = distance(__first, __first_cut);
            }
            _BidirectionalIter __new_middle =
                  __rotate_adaptive(__first_cut, __middle, __second_cut,
                                    __len1 - __len11, __len22, __buffer,
                                    __buffer_size);
            __merge_adaptive(__first, __first_cut, __new_middle,
__len11,
                             __len22, __buffer, __buffer_size, __comp);
            __merge_adaptive(__new_middle, __second_cut, __last, __len1
- __len11,
                             __len2 - __len22, __buffer, __buffer_size,
__comp);
          }
    }
# 3508 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter>
    void
    inplace_merge(_BidirectionalIter __first,
                  _BidirectionalIter __middle,
                  _BidirectionalIter __last)
    {
      typedef typename iterator_traits<_BidirectionalIter>::value_type
          _ValueType;
      typedef typename
iterator_traits<_BidirectionalIter>::difference_type
          _DistanceType;






      if (__first == __middle || __middle == __last)
        return;

      _DistanceType __len1 = distance(__first, __middle);
      _DistanceType __len2 = distance(__middle, __last);

      _Temporary_buffer<_BidirectionalIter, _ValueType> __buf(__first,
__last);
      if (__buf.begin() == 0)
        __merge_without_buffer(__first, __middle, __last, __len1,
__len2);
      else
        __merge_adaptive(__first, __middle, __last, __len1, __len2,
                         __buf.begin(), _DistanceType(__buf.size()));
    }
# 3559 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter, typename _Compare>
    void
    inplace_merge(_BidirectionalIter __first,
                  _BidirectionalIter __middle,
                  _BidirectionalIter __last,
                  _Compare __comp)
    {
      typedef typename iterator_traits<_BidirectionalIter>::value_type
          _ValueType;
      typedef typename
iterator_traits<_BidirectionalIter>::difference_type
          _DistanceType;







      if (__first == __middle || __middle == __last)
        return;

      _DistanceType __len1 = distance(__first, __middle);
      _DistanceType __len2 = distance(__middle, __last);

      _Temporary_buffer<_BidirectionalIter, _ValueType> __buf(__first,
__last);
      if (__buf.begin() == 0)
        __merge_without_buffer(__first, __middle, __last, __len1,
__len2, __comp);
      else
        __merge_adaptive(__first, __middle, __last, __len1, __len2,
                         __buf.begin(), _DistanceType(__buf.size()),
                         __comp);
    }






  template<typename _InputIter1, typename _InputIter2>
    bool
    includes(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2, _InputIter2 __last2)
    {









      while (__first1 != __last1 && __first2 != __last2)
        if (*__first2 < *__first1)
          return false;
        else if(*__first1 < *__first2)
          ++__first1;
        else
          ++__first1, ++__first2;

      return __first2 == __last2;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_Compare>
    bool
    includes(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2, _InputIter2 __last2, _Compare __comp)
    {










      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first2, *__first1))
          return false;
        else if(__comp(*__first1, *__first2))
          ++__first1;
        else
          ++__first1, ++__first2;

      return __first2 == __last2;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_union(_InputIter1 __first1, _InputIter1 __last1,
              _InputIter2 __first2, _InputIter2 __last2,
              _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2) {
        if (*__first1 < *__first2) {
          *__result = *__first1;
          ++__first1;
        }
        else if (*__first2 < *__first1) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_union(_InputIter1 __first1, _InputIter1 __last1,
              _InputIter2 __first2, _InputIter2 __last2,
              _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2) {
        if (__comp(*__first1, *__first2)) {
          *__result = *__first1;
          ++__first1;
        }
        else if (__comp(*__first2, *__first1)) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_intersection(_InputIter1 __first1, _InputIter1 __last1,
                     _InputIter2 __first2, _InputIter2 __last2,
                     _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2)
        if (*__first1 < *__first2)
          ++__first1;
        else if (*__first2 < *__first1)
          ++__first2;
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
          ++__result;
        }
      return __result;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_intersection(_InputIter1 __first1, _InputIter1 __last1,
                     _InputIter2 __first2, _InputIter2 __last2,
                     _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first1, *__first2))
          ++__first1;
        else if (__comp(*__first2, *__first1))
          ++__first2;
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
          ++__result;
        }
      return __result;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_difference(_InputIter1 __first1, _InputIter1 __last1,
                   _InputIter2 __first2, _InputIter2 __last2,
                   _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2)
        if (*__first1 < *__first2) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (*__first2 < *__first1)
          ++__first2;
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first1, __last1, __result);
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_difference(_InputIter1 __first1, _InputIter1 __last1,
                   _InputIter2 __first2, _InputIter2 __last2,
                   _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first1, *__first2)) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (__comp(*__first2, *__first1))
          ++__first2;
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first1, __last1, __result);
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_symmetric_difference(_InputIter1 __first1, _InputIter1 __last1,
                             _InputIter2 __first2, _InputIter2 __last2,
                             _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2)
        if (*__first1 < *__first2) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (*__first2 < *__first1) {
          *__result = *__first2;
          ++__first2;
          ++__result;
        }
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_symmetric_difference(_InputIter1 __first1, _InputIter1 __last1,
                             _InputIter2 __first2, _InputIter2 __last2,
                             _OutputIter __result,
                             _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first1, *__first2)) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (__comp(*__first2, *__first1)) {
          *__result = *__first2;
          ++__first2;
          ++__result;
        }
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }




  template<typename _ForwardIter>
    _ForwardIter
    max_element(_ForwardIter __first, _ForwardIter __last)
    {





      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (*__result < *__first)
          __result = __first;
      return __result;
    }

  template<typename _ForwardIter, typename _Compare>
    _ForwardIter
    max_element(_ForwardIter __first, _ForwardIter __last,
                _Compare __comp)
    {






      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (__comp(*__result, *__first)) __result = __first;
      return __result;
    }

  template<typename _ForwardIter>
    _ForwardIter
    min_element(_ForwardIter __first, _ForwardIter __last)
    {





      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (*__first < *__result)
          __result = __first;
      return __result;
    }

  template<typename _ForwardIter, typename _Compare>
    _ForwardIter
    min_element(_ForwardIter __first, _ForwardIter __last,
                _Compare __comp)
    {






      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (__comp(*__first, *__result))
          __result = __first;
      return __result;
    }




  template<typename _BidirectionalIter>
    bool
    next_permutation(_BidirectionalIter __first, _BidirectionalIter
__last)
    {





      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (*__i < *__ii) {
          _BidirectionalIter __j = __last;
          while (!(*__i < *--__j))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }

  template<typename _BidirectionalIter, typename _Compare>
    bool
    next_permutation(_BidirectionalIter __first, _BidirectionalIter
__last,
                     _Compare __comp)
    {






      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (__comp(*__i, *__ii)) {
          _BidirectionalIter __j = __last;
          while (!__comp(*__i, *--__j))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }

  template<typename _BidirectionalIter>
    bool
    prev_permutation(_BidirectionalIter __first, _BidirectionalIter
__last)
    {





      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (*__ii < *__i) {
          _BidirectionalIter __j = __last;
          while (!(*--__j < *__i))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }

  template<typename _BidirectionalIter, typename _Compare>
    bool
    prev_permutation(_BidirectionalIter __first, _BidirectionalIter
__last,
                     _Compare __comp)
    {






      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (__comp(*__ii, *__i)) {
          _BidirectionalIter __j = __last;
          while (!__comp(*--__j, *__i))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }



  template<typename _InputIter, typename _ForwardIter>
    _InputIter
    find_first_of(_InputIter __first1, _InputIter __last1,
                  _ForwardIter __first2, _ForwardIter __last2)
    {







      for ( ; __first1 != __last1; ++__first1)
        for (_ForwardIter __iter = __first2; __iter != __last2;
++__iter)
          if (*__first1 == *__iter)
            return __first1;
      return __last1;
    }

  template<typename _InputIter, typename _ForwardIter, typename
_BinaryPredicate>
    _InputIter
    find_first_of(_InputIter __first1, _InputIter __last1,
                  _ForwardIter __first2, _ForwardIter __last2,
                  _BinaryPredicate __comp)
    {










      for ( ; __first1 != __last1; ++__first1)
        for (_ForwardIter __iter = __first2; __iter != __last2;
++__iter)
          if (__comp(*__first1, *__iter))
            return __first1;
      return __last1;
    }
# 4201 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    _ForwardIter1
    __find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
               _ForwardIter2 __first2, _ForwardIter2 __last2,
               forward_iterator_tag, forward_iterator_tag)
    {
      if (__first2 == __last2)
        return __last1;
      else {
        _ForwardIter1 __result = __last1;
        while (1) {
          _ForwardIter1 __new_result
            = search(__first1, __last1, __first2, __last2);
          if (__new_result == __last1)
            return __result;
          else {
            __result = __new_result;
            __first1 = __new_result;
            ++__first1;
          }
        }
      }
    }

  template<typename _ForwardIter1, typename _ForwardIter2,
           typename _BinaryPredicate>
    _ForwardIter1
    __find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
               _ForwardIter2 __first2, _ForwardIter2 __last2,
               forward_iterator_tag, forward_iterator_tag,
               _BinaryPredicate __comp)
    {
      if (__first2 == __last2)
        return __last1;
      else {
        _ForwardIter1 __result = __last1;
        while (1) {
          _ForwardIter1 __new_result
            = search(__first1, __last1, __first2, __last2, __comp);
          if (__new_result == __last1)
            return __result;
          else {
            __result = __new_result;
            __first1 = __new_result;
            ++__first1;
          }
        }
      }
    }


  template<typename _BidirectionalIter1, typename _BidirectionalIter2>
    _BidirectionalIter1
    __find_end(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
               _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
               bidirectional_iterator_tag, bidirectional_iterator_tag)
    {




      typedef reverse_iterator<_BidirectionalIter1> _RevIter1;
      typedef reverse_iterator<_BidirectionalIter2> _RevIter2;

      _RevIter1 __rlast1(__first1);
      _RevIter2 __rlast2(__first2);
      _RevIter1 __rresult = search(_RevIter1(__last1), __rlast1,
                                   _RevIter2(__last2), __rlast2);

      if (__rresult == __rlast1)
        return __last1;
      else {
        _BidirectionalIter1 __result = __rresult.base();
        advance(__result, -distance(__first2, __last2));
        return __result;
      }
    }

  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BinaryPredicate>
    _BidirectionalIter1
    __find_end(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
               _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
               bidirectional_iterator_tag, bidirectional_iterator_tag,
               _BinaryPredicate __comp)
    {




      typedef reverse_iterator<_BidirectionalIter1> _RevIter1;
      typedef reverse_iterator<_BidirectionalIter2> _RevIter2;

      _RevIter1 __rlast1(__first1);
      _RevIter2 __rlast2(__first2);
      _RevIter1 __rresult = search(_RevIter1(__last1), __rlast1,
                                   _RevIter2(__last2), __rlast2,
                                   __comp);

      if (__rresult == __rlast1)
        return __last1;
      else {
        _BidirectionalIter1 __result = __rresult.base();
        advance(__result, -distance(__first2, __last2));
        return __result;
      }
    }



  template<typename _ForwardIter1, typename _ForwardIter2>
    inline _ForwardIter1
    find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
             _ForwardIter2 __first2, _ForwardIter2 __last2)
    {







      return __find_end(__first1, __last1, __first2, __last2,
                        __iterator_category(__first1),
                        __iterator_category(__first2));
    }

  template<typename _ForwardIter1, typename _ForwardIter2,
           typename _BinaryPredicate>
    inline _ForwardIter1
    find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
             _ForwardIter2 __first2, _ForwardIter2 __last2,
             _BinaryPredicate __comp)
    {







      return __find_end(__first1, __last1, __first2, __last2,
                        __iterator_category(__first1),
                        __iterator_category(__first2),
                        __comp);
    }

}
# 70 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 12 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 2 3 4
# 1 "/usr/local/fitools/include/g++-v3/typeinfo" 1 3 4
# 40 "/usr/local/fitools/include/g++-v3/typeinfo" 3 4
extern "C++" {

namespace __cxxabiv1
{
  class __class_type_info;
}
# 55 "/usr/local/fitools/include/g++-v3/typeinfo" 3 4
namespace std
{



  class type_info
  {
  public:




    virtual ~type_info();

  private:

    type_info& operator=(const type_info&);
    type_info(const type_info&);

  protected:
    const char *__name;

  protected:
    explicit type_info(const char *__n): __name(__n) { }

  public:



    const char* name() const
    { return __name; }
# 98 "/usr/local/fitools/include/g++-v3/typeinfo" 3 4
    bool before(const type_info& __arg) const
    { return __name < __arg.__name; }
    bool operator==(const type_info& __arg) const
    { return __name == __arg.__name; }

    bool operator!=(const type_info& __arg) const
    { return !operator==(__arg); }


  public:

    virtual bool __is_pointer_p() const;

    virtual bool __is_function_p() const;







    virtual bool __do_catch(const type_info *__thr_type, void
**__thr_obj,
                            unsigned __outer) const;


    virtual bool __do_upcast(const __cxxabiv1::__class_type_info
*__target,
                             void **__obj_ptr) const;
  };



  class bad_cast : public exception
  {
  public:
    bad_cast() throw() { }


    virtual ~bad_cast() throw();
  };


  class bad_typeid : public exception
  {
  public:
    bad_typeid () throw() { }


    virtual ~bad_typeid() throw();
  };
}

}
# 13 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 2 3 4

# 1 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 1 3 4
# 26 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 3 4
# 1 "/usr/software/fitools-any-any/sol2/boost/boost/config/user.hpp" 1 3
4
# 27 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4




# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_compiler_c
onfig.hpp" 1 3 4
# 32 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4



# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/compiler/gcc.hpp"
1 3 4
# 36 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4




# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_stdlib_con
fig.hpp" 1 3 4
# 18
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_stdlib_con
fig.hpp" 3 4
# 1 "/usr/local/fitools/include/g++-v3/utility" 1 3 4
# 65 "/usr/local/fitools/include/g++-v3/utility" 3

# 1 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 1 3
# 74 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
namespace std
{
  namespace rel_ops
  {
# 90 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator!=(const _Tp& __x, const _Tp& __y) {
  return !(__x == __y);
}
# 103 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator>(const _Tp& __x, const _Tp& __y) {
  return __y < __x;
}
# 116 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator<=(const _Tp& __x, const _Tp& __y) {
  return !(__y < __x);
}
# 129 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator>=(const _Tp& __x, const _Tp& __y) {
  return !(__x < __y);
}

  }
}
# 67 "/usr/local/fitools/include/g++-v3/utility" 2 3
# 19
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_stdlib_con
fig.hpp" 2 3 4
# 41 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4



# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/stdlib/libstdcpp3
hpp" 1 3 4
# 45 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4




# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_platform_c
onfig.hpp" 1 3 4
# 50 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4



# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/platform/solaris.
hpp" 1 3 4
# 16
"/usr/software/fitools-any-any/sol2/boost/boost/config/platform/solaris.
hpp" 3 4
# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/posix_features.hp
p" 1 3 4
# 11
"/usr/software/fitools-any-any/sol2/boost/boost/config/posix_features.hp
p" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
#pragma ident "@(#)unistd.h	1.55	98/04/14 SMI"







extern "C" {
# 209
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int access(const char *, int);


extern int acct(const char *);

extern unsigned alarm(unsigned);


extern int brk(void *);

extern int chdir(const char *);
extern int chown(const char *, uid_t, gid_t);


extern int chroot(const char *);

extern int close(int);


extern size_t confstr(int, char *, size_t);
extern char *crypt(const char *, const char *);



extern char *ctermid(char *);




extern char *cuserid(char *);
extern int dup(int);
extern int dup2(int, int);


extern void encrypt(char *, int);

extern int execl(const char *, const char *, ...);
extern int execle(const char *, const char *, ...);
extern int execlp(const char *, const char *, ...);
extern int execv(const char *, char *const *);
extern int execve(const char *, char *const *, char *const *);
extern int execvp(const char *, char *const *);
extern void _exit(int);







extern int fattach(int, const char *);



extern int fchdir(int);
extern int fchown(int, uid_t, gid_t);



extern int fchroot(int);



extern int fdatasync(int);
# 281
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int fdetach(const char *);

extern pid_t fork(void);


extern pid_t fork1(void);

extern long fpathconf(int, int);


extern int fsync(int);



extern int ftruncate(int, off_t);

extern char *getcwd(char *, size_t);


extern int getdtablesize(void);

extern gid_t getegid(void);
extern uid_t geteuid(void);
extern gid_t getgid(void);
extern int getgroups(int, gid_t *);


extern long gethostid(void);


extern int gethostname(char *, size_t);




extern char *getlogin(void);


extern int getopt(int, char *const *, const char *);
extern char *optarg;
extern int opterr, optind, optopt;
extern char *getpass(const char *);



extern int getpagesize(void);
extern pid_t getpgid(pid_t);

extern pid_t getpid(void);
extern pid_t getppid(void);
extern pid_t getpgrp(void);


char *gettxt(const char *, const char *);



extern pid_t getsid(pid_t);

extern uid_t getuid(void);


extern char *getwd(char *);
# 352
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int ioctl(int, int, ...);



extern int isaexec(const char *, char *const *, char *const *);

extern int isatty(int);
extern int link(const char *, const char *);


extern int lchown(const char *, uid_t, gid_t);
extern int lockf(int, int, off_t);
extern int readlink(const char *, char *, size_t);

extern off_t lseek(int, off_t, int);


extern int nice(int);

extern long pathconf(const char *, int);
extern int pause(void);
extern int pipe(int *);


extern offset_t llseek(int, offset_t, int);
extern off_t tell(int);
extern int mincore(caddr_t, size_t, char *);



extern ssize_t pread(int, void *, size_t, off_t);



extern void profil(unsigned short *, size_t, unsigned long, unsigned
int);



extern int pthread_atfork(void (*) (void), void (*) (void), void (*)
(void));



extern long ptrace(int, pid_t, long, long);



extern ssize_t pwrite(int, const void *, size_t, off_t);

extern ssize_t read(int, void *, size_t);


extern int rename(const char *, const char *);



extern int resolvepath(const char *, char *, size_t);

extern int rmdir(const char *);


extern void *sbrk(intptr_t);

extern int setgid(gid_t);


extern int setegid(gid_t);



extern int setgroups(int, const gid_t *);

extern int setpgid(pid_t, pid_t);


extern pid_t setpgrp(void);
extern int setregid(gid_t, gid_t);
extern int setreuid(uid_t, uid_t);

extern pid_t setsid(void);
extern int setuid(uid_t);


extern int seteuid(uid_t);

extern unsigned sleep(unsigned);


extern int stime(const time_t *);



extern void swab(const void *, void *, ssize_t);



extern int symlink(const char *, const char *);
extern void sync(void);

extern long sysconf(int);


#pragma redefine_extname sysconf __sysconf_xpg5





extern pid_t tcgetpgrp(int);
extern int tcsetpgrp(int, pid_t);


extern off_t tell(int);



extern int truncate(const char *, off_t);

extern char *ttyname(int);


extern useconds_t ualarm(useconds_t, useconds_t);

extern int unlink(const char *);


extern int usleep(useconds_t);



extern pid_t vfork(void);



extern void vhangup(void);

extern ssize_t write(int, const void *, size_t);


extern void yield(void);







extern int ftruncate64(int, off64_t);

extern off64_t lseek64(int, off64_t, int);


extern ssize_t pread64(int, void *, size_t, off64_t);
extern ssize_t pwrite64(int, const void *, size_t, off64_t);
extern off64_t tell64(int);
extern int truncate64(const char *, off64_t);
extern int lockf64(int, int, off64_t);
# 808
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
#pragma unknown_control_flow(vfork)
# 854
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int getlogin_r(char *, int);
extern int ttyname_r(int, char *, size_t);
#pragma redefine_extname getlogin_r __posix_getlogin_r
#pragma redefine_extname ttyname_r __posix_ttyname_r
# 923
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
}
# 12
"/usr/software/fitools-any-any/sol2/boost/boost/config/posix_features.hp
p" 2 3 4
# 17
"/usr/software/fitools-any-any/sol2/boost/boost/config/platform/solaris.
hpp" 2 3 4
# 54 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4



# 1 "/usr/software/fitools-any-any/sol2/boost/boost/config/suffix.hpp" 1
3 4
# 30 "/usr/software/fitools-any-any/sol2/boost/boost/config/suffix.hpp"
3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 1 3 4
# 31 "/usr/software/fitools-any-any/sol2/boost/boost/config/suffix.hpp"
2 3 4
# 58 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2 3 4
# 15 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 2 3 4

namespace boost
{
    class any
    {
    public:

        any()
          : content(0)
        {
        }

        template<typename ValueType>
        any(const ValueType & value)
          : content(new holder<ValueType>(value))
        {
        }

        any(const any & other)
          : content(other.content ? other.content->clone() : 0)
        {
        }

        ~any()
        {
            delete content;
        }

    public:

        any & swap(any & rhs)
        {
            std::swap(content, rhs.content);
            return *this;
        }

        template<typename ValueType>
        any & operator=(const ValueType & rhs)
        {
            any(rhs).swap(*this);
            return *this;
        }

        any & operator=(const any & rhs)
        {
            any(rhs).swap(*this);
            return *this;
        }

    public:

        bool empty() const
        {
            return !content;
        }

        const std::type_info & type() const
        {
            return content ? content->type() : typeid(void);
        }


    private:




        class placeholder
        {
        public:

            virtual ~placeholder()
            {
            }

        public:

            virtual const std::type_info & type() const = 0;

            virtual placeholder * clone() const = 0;

        };

        template<typename ValueType>
        class holder : public placeholder
        {
        public:

            holder(const ValueType & value)
              : held(value)
            {
            }

        public:

            virtual const std::type_info & type() const
            {
                return typeid(ValueType);
            }

            virtual placeholder * clone() const
            {
                return new holder(held);
            }

        public:

            ValueType held;

        };



    private:

        template<typename ValueType>
        friend ValueType * any_cast(any *);







        placeholder * content;

    };

    class bad_any_cast : public std::bad_cast
    {
    public:
        virtual const char * what() const throw()
        {
            return "boost::bad_any_cast: "
                   "failed conversion using boost::any_cast";
        }
    };

    template<typename ValueType>
    ValueType * any_cast(any * operand)
    {
        return operand && operand->type() == typeid(ValueType)
                    ? &static_cast<any::holder<ValueType>
*>(operand->content)->held
                    : 0;
    }

    template<typename ValueType>
    const ValueType * any_cast(const any * operand)
    {
        return any_cast<ValueType>(const_cast<any *>(operand));
    }

    template<typename ValueType>
    ValueType any_cast(const any & operand)
    {
        const ValueType * result = any_cast<ValueType>(&operand);
        if(!result)
            throw bad_any_cast();
        return *result;
    }

}
# 2 "err.cxx" 2

int main(void) {
  return 0;
}
------ end err.ii  -------


------ start errb.ii  -------
# 1 "err.cxx"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "err.cxx"
# 1 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 1
# 11 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp"
# 1 "/usr/local/fitools/include/g++-v3/algorithm" 1 3
# 65 "/usr/local/fitools/include/g++-v3/algorithm" 3

# 1 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++config.h
" 1 3
# 34
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++config.h
" 3
# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/os_defines.
h" 1 3
# 35
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++config.h
" 2 3
# 65 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/cstring" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cstring" 3

# 1 "/usr/local/fitools/include/g++-v3/cstddef" 1 3
# 47 "/usr/local/fitools/include/g++-v3/cstddef" 3

# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 1 3 4
# 147
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 3 4
typedef int ptrdiff_t;
# 201
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 3 4
typedef unsigned int size_t;
# 49 "/usr/local/fitools/include/g++-v3/cstddef" 2 3

namespace std
{
  using ::ptrdiff_t;
  using ::size_t;
}
# 50 "/usr/local/fitools/include/g++-v3/cstring" 2 3

# 1 "/usr/include/string.h" 1 3 4
# 16 "/usr/include/string.h" 3 4
#pragma ident "@(#)string.h	1.22	97/12/22 SMI"

# 1 "/usr/include/sys/feature_tests.h" 1 3 4
# 13 "/usr/include/sys/feature_tests.h" 3 4
#pragma ident "@(#)feature_tests.h	1.17	97/12/04 SMI"

# 1 "/usr/include/sys/isa_defs.h" 1 3 4
# 9 "/usr/include/sys/isa_defs.h" 3 4
#pragma ident "@(#)isa_defs.h	1.16	99/05/25 SMI"
# 148 "/usr/include/sys/isa_defs.h" 3 4
extern "C" {
# 330 "/usr/include/sys/isa_defs.h" 3 4
}
# 16 "/usr/include/sys/feature_tests.h" 2 3 4


extern "C" {
# 175 "/usr/include/sys/feature_tests.h" 3 4
}
# 19 "/usr/include/string.h" 2 3 4


extern "C" {
# 43 "/usr/include/string.h" 3 4
extern void *memcpy(void *, const void *, size_t);
extern void *memmove(void *, const void *, size_t);
extern char *strcpy(char *, const char *);
extern char *strncpy(char *, const char *, size_t);

extern char *strcat(char *, const char *);
extern char *strncat(char *, const char *, size_t);

extern int memcmp(const void *, const void *, size_t);
extern int strcmp(const char *, const char *);
extern int strcoll(const char *, const char *);
extern int strncmp(const char *, const char *, size_t);
extern size_t strxfrm(char *, const char *, size_t);

extern void *memchr(const void *, int, size_t);
extern char *strchr(const char *, int);
extern size_t strcspn(const char *, const char *);
extern char *strpbrk(const char *, const char *);
extern char *strrchr(const char *, int);
extern size_t strspn(const char *, const char *);
extern char *strstr(const char *, const char *);
extern char *strtok(char *, const char *);


extern char *strtok_r(char *, const char *, char **);

extern void *memset(void *, int, size_t);
extern char *strerror(int);
extern size_t strlen(const char *);



extern void *memccpy(void *, const void *, int, size_t);




extern char *strsignal(int);
extern int ffs(int);
extern int strcasecmp(const char *, const char *);
extern int strncasecmp(const char *, const char *, size_t);





extern char *strdup(const char *);
# 146 "/usr/include/string.h" 3 4
}
# 52 "/usr/local/fitools/include/g++-v3/cstring" 2 3
# 77 "/usr/local/fitools/include/g++-v3/cstring" 3
namespace std
{
  using ::memcpy;
  using ::memmove;
  using ::strcpy;
  using ::strncpy;
  using ::strcat;
  using ::strncat;
  using ::memcmp;
  using ::strcmp;
  using ::strcoll;
  using ::strncmp;
  using ::strxfrm;
  using ::strcspn;
  using ::strspn;
  using ::strtok;
  using ::memset;
  using ::strerror;
  using ::strlen;

  using ::memchr;

  inline void*
  memchr(void* __p, int __c, size_t __n)
  { return memchr(const_cast<const void*>(__p), __c, __n); }

  using ::strchr;

  inline char*
  strchr(char* __s1, int __n)
  { return __builtin_strchr(const_cast<const char*>(__s1), __n); }

  using ::strpbrk;

  inline char*
  strpbrk(char* __s1, const char* __s2)
  { return __builtin_strpbrk(const_cast<const char*>(__s1), __s2); }

  using ::strrchr;

  inline char*
  strrchr(char* __s1, int __n)
  { return __builtin_strrchr(const_cast<const char*>(__s1), __n); }

  using ::strstr;

  inline char*
  strstr(char* __s1, const char* __s2)
  { return __builtin_strstr(const_cast<const char*>(__s1), __s2); }
}
# 66 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/climits" 1 3
# 48 "/usr/local/fitools/include/g++-v3/climits" 3

# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 1 3 4
# 11
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
#pragma ident "@(#)limits.h	1.48	98/07/20 SMI"
# 40
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
# 1 "/usr/include/sys/int_limits.h" 1 3 4
# 9 "/usr/include/sys/int_limits.h" 3 4
#pragma ident "@(#)int_limits.h	1.5	98/01/06 SMI"
# 47 "/usr/include/sys/int_limits.h" 3 4
extern "C" {
# 162 "/usr/include/sys/int_limits.h" 3 4
}
# 41
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 2 3 4



extern "C" {
# 282
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
typedef long clock_t;


extern long _sysconf(int);
# 307
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
# 1 "/usr/include/sys/unistd.h" 1 3 4
# 25 "/usr/include/sys/unistd.h" 3 4
#pragma ident "@(#)unistd.h	1.36	98/07/16 SMI"




extern "C" {
# 264 "/usr/include/sys/unistd.h" 3 4
}
# 308
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 2 3 4
# 318
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
extern long _sysconf(int);
# 328
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
slimits.h" 3 4
}
# 12
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 2 3 4
# 50 "/usr/local/fitools/include/g++-v3/climits" 2 3
# 67 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/cstdlib" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cstdlib" 3




# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
#pragma ident "@(#)stdlib.h	1.44	98/01/22 SMI"





# 1 "/usr/include/sys/wait.h" 1 3 4
# 16 "/usr/include/sys/wait.h" 3 4
#pragma ident "@(#)wait.h	1.21	97/04/08 SMI"



# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
#pragma ident "@(#)types.h	1.63	98/04/28 SMI"







# 1 "/usr/include/sys/machtypes.h" 1 3 4
# 16 "/usr/include/sys/machtypes.h" 3 4
#pragma ident "@(#)machtypes.h	1.12	96/08/01 SMI"




extern "C" {
# 33 "/usr/include/sys/machtypes.h" 3 4
typedef struct _physadr_t { int r[1]; } *physadr_t;

typedef struct _label_t { long val[2]; } label_t;



typedef unsigned char lock_t;


}
# 34
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 2 3 4
# 45
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
# 1 "/usr/include/sys/int_types.h" 1 3 4
# 9 "/usr/include/sys/int_types.h" 3 4
#pragma ident "@(#)int_types.h	1.6	97/08/20 SMI"
# 45 "/usr/include/sys/int_types.h" 3 4
extern "C" {
# 62 "/usr/include/sys/int_types.h" 3 4
typedef char int8_t;





typedef short int16_t;
typedef int int32_t;




typedef long long int64_t;



typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;




typedef unsigned long long uint64_t;
# 94 "/usr/include/sys/int_types.h" 3 4
typedef int64_t intmax_t;
typedef uint64_t uintmax_t;
# 110 "/usr/include/sys/int_types.h" 3 4
typedef int intptr_t;
typedef unsigned int uintptr_t;







typedef char int_least8_t;





typedef short int_least16_t;
typedef int int_least32_t;




typedef long long int_least64_t;



typedef unsigned char uint_least8_t;
typedef unsigned short uint_least16_t;
typedef unsigned int uint_least32_t;




typedef unsigned long long uint_least64_t;




}
# 46
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 2 3 4







extern "C" {
# 62
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long long longlong_t;
typedef unsigned long long u_longlong_t;
# 85
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long t_scalar_t;
typedef unsigned long t_uscalar_t;





typedef unsigned char uchar_t;
typedef unsigned short ushort_t;
typedef unsigned int uint_t;
typedef unsigned long ulong_t;

typedef char *caddr_t;
typedef long daddr_t;
typedef short cnt_t;


typedef ulong_t paddr_t;
# 125
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef ulong_t pfn_t;
typedef ulong_t pgcnt_t;
typedef long spgcnt_t;

typedef uchar_t use_t;
typedef short sysid_t;
typedef short index_t;
typedef void *timeout_id_t;
typedef void *bufcall_id_t;
# 147
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long off_t;
# 156
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef longlong_t off64_t;






typedef ulong_t ino_t;
typedef long blkcnt_t;
typedef ulong_t fsblkcnt_t;
typedef ulong_t fsfilcnt_t;
# 181
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef u_longlong_t ino64_t;
typedef longlong_t blkcnt64_t;
typedef u_longlong_t fsblkcnt64_t;
typedef u_longlong_t fsfilcnt64_t;






typedef long blksize_t;



typedef enum { _B_FALSE, _B_TRUE } boolean_t;
# 208
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef int64_t pad64_t;
typedef uint64_t upad64_t;
# 221
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef longlong_t offset_t;
typedef u_longlong_t u_offset_t;
typedef u_longlong_t len_t;
typedef longlong_t diskaddr_t;
# 242
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef union {
        offset_t _f;
        struct {
                int32_t _u;
                int32_t _l;
        } _p;
} lloff_t;
# 262
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef union {
        diskaddr_t _f;
        struct {
                int32_t _u;
                int32_t _l;
        } _p;
} lldaddr_t;


typedef uint_t k_fltset_t;
# 287
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef long id_t;






typedef uint_t useconds_t;



typedef long suseconds_t;
# 308
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef ulong_t major_t;
typedef ulong_t minor_t;





typedef short pri_t;
# 328
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef ushort_t o_mode_t;
typedef short o_dev_t;
typedef ushort_t o_uid_t;
typedef o_uid_t o_gid_t;
typedef short o_nlink_t;
typedef short o_pid_t;
typedef ushort_t o_ino_t;





typedef int key_t;



typedef ulong_t mode_t;







typedef long uid_t;



typedef uid_t gid_t;






typedef unsigned int pthread_t;
typedef unsigned int pthread_key_t;

typedef struct _pthread_mutex {
        struct {
                uint8_t __pthread_mutex_flag[4];
                uint32_t __pthread_mutex_type;
        } __pthread_mutex_flags;
        union {
                struct {
                        uint8_t __pthread_mutex_pad[8];
                } __pthread_mutex_lock64;
                upad64_t __pthread_mutex_owner64;
        } __pthread_mutex_lock;
        upad64_t __pthread_mutex_data;
} pthread_mutex_t;

typedef struct _pthread_cond {
        struct {
                uint8_t __pthread_cond_flag[4];
                uint32_t __pthread_cond_type;
        } __pthread_cond_flags;
        upad64_t __pthread_cond_data;
} pthread_cond_t;




typedef struct _pthread_rwlock {
        int32_t __pthread_rwlock_readers;
        uint16_t __pthread_rwlock_type;
        uint16_t __pthread_rwlock_magic;
        upad64_t __pthread_rwlock_pad1[3];
        upad64_t __pthread_rwlock_pad2[2];
        upad64_t __pthread_rwlock_pad3[2];
} pthread_rwlock_t;




typedef struct _pthread_attr {
        void *__pthread_attrp;
} pthread_attr_t;





typedef struct _pthread_mutexattr {
        void *__pthread_mutexattrp;
} pthread_mutexattr_t;





typedef struct _pthread_condattr {
        void *__pthread_condattrp;
} pthread_condattr_t;




typedef struct _once {
        upad64_t __pthread_once_pad[4];
} pthread_once_t;





typedef struct _pthread_rwlockattr {
        void *__pthread_rwlockattrp;
} pthread_rwlockattr_t;

typedef ulong_t dev_t;





typedef ulong_t nlink_t;
typedef long pid_t;
# 470
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef int ssize_t;





typedef long time_t;
# 486
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef int clockid_t;




typedef int timer_t;






typedef unsigned char unchar;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef unsigned long ulong;
# 552
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
typedef struct _quad { int val[2]; } quad_t;
typedef quad_t quad;






# 1 "/usr/include/sys/select.h" 1 3 4
# 12 "/usr/include/sys/select.h" 3 4
#pragma ident "@(#)select.h	1.16	98/04/27 SMI"




# 1 "/usr/include/sys/time.h" 1 3 4
# 22 "/usr/include/sys/time.h" 3 4
#pragma ident "@(#)time.h	2.62	98/02/04 SMI"
# 32 "/usr/include/sys/time.h" 3 4
extern "C" {
# 49 "/usr/include/sys/time.h" 3 4
struct timeval {
        time_t tv_sec;
        suseconds_t tv_usec;
};
# 82 "/usr/include/sys/time.h" 3 4
struct timezone {
        int tz_minuteswest;
        int tz_dsttime;
};





}
# 100 "/usr/include/sys/time.h" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 1 3 4
# 101 "/usr/include/sys/time.h" 2 3 4



extern "C" {
# 155 "/usr/include/sys/time.h" 3 4
struct itimerval {
        struct timeval it_interval;
        struct timeval it_value;
};
# 203 "/usr/include/sys/time.h" 3 4
typedef longlong_t hrtime_t;
# 315 "/usr/include/sys/time.h" 3 4
int adjtime(struct timeval *, struct timeval *);
# 326 "/usr/include/sys/time.h" 3 4
int getitimer(int, struct itimerval *);
int utimes(const char *, const struct timeval *);

int setitimer(int, const struct itimerval *, struct itimerval *);
# 364 "/usr/include/sys/time.h" 3 4
int settimeofday(struct timeval *, void *);

hrtime_t gethrtime(void);
hrtime_t gethrvtime(void);
# 384 "/usr/include/sys/time.h" 3 4
int gettimeofday(struct timeval *, void *);
# 405 "/usr/include/sys/time.h" 3 4
# 1 "/usr/include/time.h" 1 3 4
# 16 "/usr/include/time.h" 3 4
#pragma ident "@(#)time.h	1.36	98/03/27 SMI"





extern "C" {
# 64 "/usr/include/time.h" 3 4
struct tm {
        int tm_sec;
        int tm_min;
        int tm_hour;
        int tm_mday;
        int tm_mon;
        int tm_year;
        int tm_wday;
        int tm_yday;
        int tm_isdst;
};



extern clock_t clock(void);
extern double difftime(time_t, time_t);
extern time_t mktime(struct tm *);
extern time_t time(time_t *);
extern char *asctime(const struct tm *);
extern char *ctime(const time_t *);
extern struct tm *gmtime(const time_t *);
extern struct tm *localtime(const time_t *);
extern size_t strftime(char *, size_t, const char *, const struct tm *);



extern struct tm *gmtime_r(const time_t *, struct tm *);
extern struct tm *localtime_r(const time_t *, struct tm *);





extern char *strptime(const char *, const char *, struct tm *);





# 1 "/usr/include/sys/time_impl.h" 1 3 4
# 15 "/usr/include/sys/time_impl.h" 3 4
#pragma ident "@(#)time_impl.h	1.3	98/02/13 SMI"




extern "C" {
# 36 "/usr/include/sys/time_impl.h" 3 4
typedef struct timespec {
        time_t tv_sec;
        long tv_nsec;
} timespec_t;
# 60 "/usr/include/sys/time_impl.h" 3 4
typedef struct timespec timestruc_t;
# 79 "/usr/include/sys/time_impl.h" 3 4
typedef struct itimerspec {
        struct timespec it_interval;
        struct timespec it_value;
} itimerspec_t;
# 130 "/usr/include/sys/time_impl.h" 3 4
}
# 104 "/usr/include/time.h" 2 3 4
# 118 "/usr/include/time.h" 3 4
union sigval {
        int sival_int;
        void *sival_ptr;
};




struct sigevent {
        int sigev_notify;
        int sigev_signo;
        union sigval sigev_value;
        void (*sigev_notify_function)(union sigval);
        pthread_attr_t *sigev_notify_attributes;
        int __sigev_pad2;
};


extern int clock_getres(clockid_t, struct timespec *);
extern int clock_gettime(clockid_t, struct timespec *);
extern int clock_settime(clockid_t, const struct timespec *);
extern int timer_create(clockid_t, struct sigevent *, timer_t *);
extern int timer_delete(timer_t);
extern int timer_getoverrun(timer_t);
extern int timer_gettime(timer_t, struct itimerspec *);
extern int timer_settime(timer_t, int, const struct itimerspec *,
                struct itimerspec *);
extern int nanosleep(const struct timespec *, struct timespec *);




extern void tzset(void);

extern char *tzname[2];
# 162 "/usr/include/time.h" 3 4
extern long timezone;
extern int daylight;
# 176 "/usr/include/time.h" 3 4
extern struct tm *getdate(const char *);






extern int getdate_err;
# 266 "/usr/include/time.h" 3 4
extern char *asctime_r(const struct tm *, char *);
extern char *ctime_r(const time_t *, char *);
#pragma redefine_extname ctime_r __posix_ctime_r
#pragma redefine_extname asctime_r __posix_asctime_r
# 334 "/usr/include/time.h" 3 4
}
# 406 "/usr/include/sys/time.h" 2 3 4
# 418 "/usr/include/sys/time.h" 3 4
# 1 "/usr/include/sys/select.h" 1 3 4
# 419 "/usr/include/sys/time.h" 2 3 4





}
# 18 "/usr/include/sys/select.h" 2 3 4



extern "C" {
# 45 "/usr/include/sys/select.h" 3 4
typedef long fd_mask;

typedef long fds_mask;
# 73 "/usr/include/sys/select.h" 3 4
typedef struct fd_set {



        long fds_bits[(((1024)+(((sizeof (fds_mask) * 8))-1))/((sizeof
(fds_mask) * 8)))];
} fd_set;
# 97 "/usr/include/sys/select.h" 3 4
extern int select(int, fd_set *, fd_set *, fd_set *, struct timeval *);






}
# 565
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 2 3 4
# 581
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/sy
s/types.h" 3 4
}
# 21 "/usr/include/sys/wait.h" 2 3 4



# 1 "/usr/include/sys/resource.h" 1 3 4
# 16 "/usr/include/sys/resource.h" 3 4
#pragma ident "@(#)resource.h	1.25	98/06/30 SMI"







extern "C" {
# 67 "/usr/include/sys/resource.h" 3 4
typedef unsigned long rlim_t;
# 102 "/usr/include/sys/resource.h" 3 4
struct rlimit {
        rlim_t rlim_cur;
        rlim_t rlim_max;
};




typedef u_longlong_t rlim64_t;





struct rlimit64 {
        rlim64_t rlim_cur;
        rlim64_t rlim_max;
};
# 143 "/usr/include/sys/resource.h" 3 4
struct rusage {
        struct timeval ru_utime;
        struct timeval ru_stime;
        long ru_maxrss;
        long ru_ixrss;
        long ru_idrss;
        long ru_isrss;
        long ru_minflt;
        long ru_majflt;
        long ru_nswap;
        long ru_inblock;
        long ru_oublock;
        long ru_msgsnd;
        long ru_msgrcv;
        long ru_nsignals;
        long ru_nvcsw;
        long ru_nivcsw;
};
# 193 "/usr/include/sys/resource.h" 3 4
extern int setrlimit(int, const struct rlimit *);
extern int getrlimit(int, struct rlimit *);




extern int setrlimit64(int, const struct rlimit64 *);
extern int getrlimit64(int, struct rlimit64 *);


extern int getpriority(int, id_t);
extern int setpriority(int, id_t, int);
extern int getrusage(int, struct rusage *);
# 228 "/usr/include/sys/resource.h" 3 4
}
# 25 "/usr/include/sys/wait.h" 2 3 4
# 1 "/usr/include/sys/siginfo.h" 1 3 4
# 16 "/usr/include/sys/siginfo.h" 3 4
#pragma ident "@(#)siginfo.h	1.54	98/03/27 SMI"





extern "C" {
# 126 "/usr/include/sys/siginfo.h" 3 4
# 1 "/usr/include/sys/machsig.h" 1 3 4
# 16 "/usr/include/sys/machsig.h" 3 4
#pragma ident "@(#)machsig.h	1.14	98/02/05 SMI"





extern "C" {
# 110 "/usr/include/sys/machsig.h" 3 4
}
# 127 "/usr/include/sys/siginfo.h" 2 3 4
# 221 "/usr/include/sys/siginfo.h" 3 4
typedef struct siginfo {



        int si_signo;
        int si_code;
        int si_errno;



        union {

                int __pad[((128 / sizeof (int)) - 3)];

                struct {
                        pid_t __pid;
                        union {
                                struct {
                                        uid_t __uid;


                                        union sigval __value;



                                } __kill;
                                struct {
                                        clock_t __utime;
                                        int __status;
                                        clock_t __stime;
                                } __cld;
                        } __pdata;
                } __proc;

                struct {
                        void *__addr;
                        int __trapno;
                        caddr_t __pc;
                } __fault;

                struct {

                        int __fd;
                        long __band;
                } __file;

                struct {
                        caddr_t __faddr;


                        timestruc_t __tstamp;



                        short __syscall;
                        char __nsysarg;
                        char __fault;
                        long __sysarg[8];
                        int __mstate[10];
                } __prof;

        } __data;

} siginfo_t;
# 354 "/usr/include/sys/siginfo.h" 3 4
typedef struct k_siginfo {
        int si_signo;
        int si_code;
        int si_errno;



        union {
                struct {
                        pid_t __pid;
                        union {
                                struct {
                                        uid_t __uid;
                                        union sigval __value;
                                } __kill;
                                struct {
                                        clock_t __utime;
                                        int __status;
                                        clock_t __stime;
                                } __cld;
                        } __pdata;
                } __proc;

                struct {
                        void *__addr;
                        int __trapno;
                        caddr_t __pc;
                } __fault;

                struct {

                        int __fd;
                        long __band;
                } __file;

                struct {
                        caddr_t __faddr;



                        timestruc_t __tstamp;



                        short __syscall;
                        char __nsysarg;
                        char __fault;



                } __prof;

        } __data;

} k_siginfo_t;

typedef struct sigqueue {
        struct sigqueue *sq_next;
        k_siginfo_t sq_info;
        void (*sq_func)(struct sigqueue *);
        void *sq_backptr;

} sigqueue_t;
# 454 "/usr/include/sys/siginfo.h" 3 4
}
# 26 "/usr/include/sys/wait.h" 2 3 4
# 1 "/usr/include/sys/procset.h" 1 3 4
# 16 "/usr/include/sys/procset.h" 3 4
#pragma ident "@(#)procset.h	1.18	98/06/30 SMI"


extern "C" {
# 40 "/usr/include/sys/procset.h" 3 4
typedef enum

        idtype

                {
        P_PID,
        P_PPID,
        P_PGID,

        P_SID,
        P_CID,
        P_UID,
        P_GID,
        P_ALL,
        P_LWPID
} idtype_t;
# 64 "/usr/include/sys/procset.h" 3 4
typedef enum idop {
        POP_DIFF,


        POP_AND,


        POP_OR,


        POP_XOR


} idop_t;







typedef struct procset {
        idop_t p_op;




        idtype_t p_lidtype;


        id_t p_lid;

        idtype_t p_ridtype;


        id_t p_rid;
} procset_t;
# 129 "/usr/include/sys/procset.h" 3 4
}
# 27 "/usr/include/sys/wait.h" 2 3 4



extern "C" {
# 86 "/usr/include/sys/wait.h" 3 4
extern pid_t wait(int *);
extern pid_t waitpid(pid_t, int *, int);


extern int waitid(idtype_t, id_t, siginfo_t *, int);
extern pid_t wait3(int *, int, struct rusage *);




extern pid_t wait4(pid_t, int *, int, struct rusage *);
# 118 "/usr/include/sys/wait.h" 3 4
}
# 32
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 2 3 4



extern "C" {


typedef struct {
        int quot;
        int rem;
} div_t;

typedef struct {
        long quot;
        long rem;
} ldiv_t;


typedef struct {
        long long quot;
        long long rem;
} lldiv_t;
# 148
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
extern unsigned char __ctype[];



extern double atof(const char *);
extern int atoi(const char *);
extern long int atol(const char *);
extern double strtod(const char *, char **);
extern long int strtol(const char *, char **, int);
extern unsigned long int strtoul(const char *, char **, int);

extern int rand(void);
extern void srand(unsigned int);


extern int rand_r(unsigned int *);


extern void *calloc(size_t, size_t);
extern void free(void *);
extern void *malloc(size_t);
extern void *realloc(void *, size_t);

extern void abort(void);
extern int atexit(void (*)(void));
extern void exit(int);
extern void _exithandle(void);
extern char *getenv(const char *);
extern int system(const char *);

extern void *bsearch(const void *, const void *, size_t, size_t,
        int (*)(const void *, const void *));
extern void qsort(void *, size_t, size_t,
        int (*)(const void *, const void *));

extern int abs(int);
extern div_t div(int, int);
extern long int labs(long);
extern ldiv_t ldiv(long, long);

extern int mbtowc(wchar_t *, const char *, size_t);
extern int mblen(const char *, size_t);
extern int wctomb(char *, wchar_t);

extern size_t mbstowcs(wchar_t *, const char *, size_t);
extern size_t wcstombs(char *, const wchar_t *, size_t);




extern double drand48(void);
extern double erand48(unsigned short *);
extern long jrand48(unsigned short *);
extern void lcong48(unsigned short *);
extern long lrand48(void);
extern long mrand48(void);
extern long nrand48(unsigned short *);
extern unsigned short *seed48(unsigned short *);
extern void srand48(long);
extern int putenv(char *);
extern void setkey(const char *);
# 219
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
extern int mkstemp(char *);


extern int mkstemp64(char *);






extern long a64l(const char *);
extern char *ecvt(double, int, int *, int *);
extern char *fcvt(double, int, int *, int *);
extern char *gcvt(double, int, char *);
extern int getsubopt(char **, char *const *, char **);
extern int grantpt(int);
extern char *initstate(unsigned, char *, size_t);
extern char *l64a(long);
extern char *mktemp(char *);
extern char *ptsname(int);
extern long random(void);
extern char *realpath(const char *, char *);
extern char *setstate(const char *);
extern void srandom(unsigned);
extern int ttyslot(void);
extern int unlockpt(int);
extern void *valloc(size_t);




extern int dup2(int, int);
extern char *qecvt(long double, int, int *, int *);
extern char *qfcvt(long double, int, int *, int *);
extern char *qgcvt(long double, int, char *);
extern char *getcwd(char *, size_t);
extern const char *getexecname(void);
extern char *getlogin(void);
extern int getopt(int, char *const *, const char *);
extern char *optarg;
extern int optind, opterr, optopt;
extern char *getpass(const char *);
extern char *getpassphrase(const char *);
extern int getpw(uid_t, char *);
extern int isatty(int);
extern void *memalign(size_t, size_t);
extern char *ttyname(int);


extern long long atoll(const char *);
extern long long llabs(long long);
extern lldiv_t lldiv(long long, long long);
extern char *lltostr(long long, char *);
extern long long strtoll(const char *, char **, int);
extern unsigned long long strtoull(const char *, char **, int);
extern char *ulltostr(unsigned long long, char *);
# 412
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dlib.h" 3 4
}
# 53 "/usr/local/fitools/include/g++-v3/cstdlib" 2 3
# 84 "/usr/local/fitools/include/g++-v3/cstdlib" 3
namespace std
{
  using ::div_t;
  using ::ldiv_t;

  using ::abort;
  using ::abs;
  using ::atexit;
  using ::atof;
  using ::atoi;
  using ::atol;
  using ::bsearch;
  using ::calloc;
  using ::div;
  using ::exit;
  using ::free;
  using ::getenv;
  using ::labs;
  using ::ldiv;
  using ::malloc;
  using ::mblen;
  using ::mbstowcs;
  using ::mbtowc;
  using ::qsort;
  using ::rand;
  using ::realloc;
  using ::srand;
  using ::strtod;
  using ::strtol;
  using ::strtoul;
  using ::system;
  using ::wcstombs;
  using ::wctomb;

  inline long
  abs(long __i) { return labs(__i); }

  inline ldiv_t
  div(long __i, long __j) { return ldiv(__i, __j); }
}
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3

# 1 "/usr/local/fitools/include/g++-v3/new" 1 3
# 42 "/usr/local/fitools/include/g++-v3/new" 3
# 1 "/usr/local/fitools/include/g++-v3/exception" 1 3
# 40 "/usr/local/fitools/include/g++-v3/exception" 3
extern "C++" {

namespace std
{






  class exception
  {
  public:
    exception() throw() { }
    virtual ~exception() throw();


    virtual const char* what() const throw();
  };



  class bad_exception : public exception
  {
  public:
    bad_exception() throw() { }


    virtual ~bad_exception() throw();
  };


  typedef void (*terminate_handler) ();

  typedef void (*unexpected_handler) ();


  terminate_handler set_terminate(terminate_handler) throw();


  void terminate() __attribute__ ((__noreturn__));


  unexpected_handler set_unexpected(unexpected_handler) throw();


  void unexpected() __attribute__ ((__noreturn__));
# 98 "/usr/local/fitools/include/g++-v3/exception" 3
  bool uncaught_exception() throw();
}

namespace __gnu_cxx
{
# 111 "/usr/local/fitools/include/g++-v3/exception" 3
  void __verbose_terminate_handler ();
}

}
# 43 "/usr/local/fitools/include/g++-v3/new" 2 3

extern "C++" {

namespace std
{


  class bad_alloc : public exception
  {
  public:
    bad_alloc() throw() { }


    virtual ~bad_alloc() throw();
  };

  struct nothrow_t { };
  extern const nothrow_t nothrow;


  typedef void (*new_handler)();

  new_handler set_new_handler(new_handler);
}
# 79 "/usr/local/fitools/include/g++-v3/new" 3
void* operator new(std::size_t) throw (std::bad_alloc);
void* operator new[](std::size_t) throw (std::bad_alloc);
void operator delete(void*) throw();
void operator delete[](void*) throw();
void* operator new(std::size_t, const std::nothrow_t&) throw();
void* operator new[](std::size_t, const std::nothrow_t&) throw();
void operator delete(void*, const std::nothrow_t&) throw();
void operator delete[](void*, const std::nothrow_t&) throw();


inline void* operator new(std::size_t, void* __p) throw() { return __p;
}
inline void* operator new[](std::size_t, void* __p) throw() { return
__p; }

}
# 70 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/iosfwd" 1 3
# 43 "/usr/local/fitools/include/g++-v3/iosfwd" 3


# 1 "/usr/local/fitools/include/g++-v3/bits/stringfwd.h" 1 3
# 43 "/usr/local/fitools/include/g++-v3/bits/stringfwd.h" 3



namespace std
{
  template<class _CharT>
    struct char_traits;

  template<> struct char_traits<char>;




  template<typename _Alloc>
    class allocator;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_string;

  typedef basic_string<char> string;
  typedef basic_string<wchar_t> wstring;
}
# 46 "/usr/local/fitools/include/g++-v3/iosfwd" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 1 3
# 43 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 3

# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 1
3
# 35
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 3
# 1 "/usr/local/fitools/include/g++-v3/cstdio" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cstdio" 3




# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 1 3 4
# 14
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
darg.h" 1 3 4
# 43
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
darg.h" 3 4
typedef __builtin_va_list __gnuc_va_list;
# 15
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 34
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
#pragma ident "@(#)stdio.h	1.69	98/07/13 SMI"


# 1 "/usr/include/sys/va_list.h" 1 3 4
# 9 "/usr/include/sys/va_list.h" 3 4
#pragma ident "@(#)va_list.h	1.11	97/11/22 SMI"
# 22 "/usr/include/sys/va_list.h" 3 4
extern "C" {



typedef void *__va_list;





}
# 38
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio_tag.h" 1 3 4
# 18
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio_tag.h" 3 4
#pragma ident "@(#)stdio_tag.h	1.3	98/04/20 SMI"


extern "C" {
# 30
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio_tag.h" 3 4
typedef struct __FILE __FILE;



}
# 39
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 1 "/usr/include/stdio_impl.h" 1 3 4
# 9 "/usr/include/stdio_impl.h" 3 4
#pragma ident "@(#)stdio_impl.h	1.8	99/06/30 SMI"




extern "C" {
# 38 "/usr/include/stdio_impl.h" 3 4
struct __FILE
{




        ssize_t _cnt;
        unsigned char *_ptr;

        unsigned char *_base;
        unsigned char _flag;
        unsigned char _file;
        unsigned __orientation:2;
        unsigned __ionolock:1;
        unsigned __filler:5;
};




}
# 40
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 2 3 4
# 50
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern "C" {




typedef __FILE FILE;
# 74
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
typedef long long __longlong_t;
# 103
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
typedef long fpos_t;







typedef __longlong_t fpos64_t;
# 132
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
typedef __va_list __not_va_list__;
# 203
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE __iob[20];
# 215
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern unsigned char _sibuf[], _sobuf[];
# 244
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern unsigned char *_bufendtab[];
extern FILE *_lastbuf;
# 275
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern int remove(const char *);
extern int rename(const char *, const char *);
extern FILE *tmpfile(void);
extern char *tmpnam(char *);

extern char *tmpnam_r(char *);

extern int fclose(FILE *);
extern int fflush(FILE *);
extern FILE *fopen(const char *, const char *);
extern FILE *freopen(const char *, const char *, FILE *);
extern void setbuf(FILE *, char *);


extern void setbuffer(FILE *, char *, size_t);
extern int setlinebuf(FILE *);

extern int setvbuf(FILE *, char *, int, size_t);

extern int fprintf(FILE *, const char *, ...);

extern int fscanf(FILE *, const char *, ...);

extern int printf(const char *, ...);

extern int scanf(const char *, ...);




extern int snprintf(char *, size_t, const char *, ...);


extern int sprintf(char *, const char *, ...);

extern int sscanf(const char *, const char *, ...);
extern int vfprintf(FILE *, const char *, __gnuc_va_list);
extern int vprintf(const char *, __gnuc_va_list);



extern int vsnprintf(char *, size_t, const char *, __gnuc_va_list);

extern int vsprintf(char *, const char *, __gnuc_va_list);
extern int fgetc(FILE *);
extern char *fgets(char *, int, FILE *);
extern int fputc(int, FILE *);
extern int fputs(const char *, FILE *);
extern int getc(FILE *);
extern int getchar(void);
extern char *gets(char *);
extern int putc(int, FILE *);
extern int putchar(int);
extern int puts(const char *);
extern int ungetc(int, FILE *);
extern size_t fread(void *, size_t, size_t, FILE *);
extern size_t fwrite(const void *, size_t, size_t, FILE *);
extern int fgetpos(FILE *, fpos_t *);
extern int fseek(FILE *, long, int);
extern int fsetpos(FILE *, const fpos_t *);
extern long ftell(FILE *);
extern void rewind(FILE *);
extern void clearerr(FILE *);
extern int feof(FILE *);
extern int ferror(FILE *);
extern void perror(const char *);


extern int __filbuf(FILE *);
extern int __flsbuf(int, FILE *);
# 353
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE *fdopen(int, const char *);
extern char *ctermid(char *);
extern int fileno(FILE *);
# 364
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern void flockfile(FILE *);
extern int ftrylockfile(FILE *);
extern void funlockfile(FILE *);
extern int getc_unlocked(FILE *);
extern int getchar_unlocked(void);
extern int putc_unlocked(int, FILE *);
extern int putchar_unlocked(int);
# 379
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE *popen(const char *, const char *);
extern char *cuserid(char *);
extern char *tempnam(const char *, const char *);
extern int getopt(int, char *const *, const char *);



extern char *optarg;
extern int optind, opterr, optopt;
extern int getw(FILE *);
extern int putw(int, FILE *);
extern int pclose(FILE *);







extern int fseeko(FILE *, off_t, int);
extern off_t ftello(FILE *);
# 408
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
extern FILE *fopen64(const char *, const char *);
extern FILE *freopen64(const char *, const char *, FILE *);
extern FILE *tmpfile64(void);
extern int fgetpos64(FILE *, fpos64_t *);
extern int fsetpos64(FILE *, const fpos64_t *);
extern int fseeko64(FILE *, off64_t, int);
extern off64_t ftello64(FILE *);
# 586
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
dio.h" 3 4
}
# 53 "/usr/local/fitools/include/g++-v3/cstdio" 2 3
# 97 "/usr/local/fitools/include/g++-v3/cstdio" 3
namespace std
{
  using ::FILE;
  using ::fpos_t;

  using ::clearerr;
  using ::fclose;
  using ::feof;
  using ::ferror;
  using ::fflush;
  using ::fgetc;
  using ::fgetpos;
  using ::fgets;
  using ::fopen;
  using ::fprintf;
  using ::fputc;
  using ::fputs;
  using ::fread;
  using ::freopen;
  using ::fscanf;
  using ::fseek;
  using ::fsetpos;
  using ::ftell;
  using ::fwrite;
  using ::getc;
  using ::getchar;
  using ::gets;
  using ::perror;
  using ::printf;
  using ::putc;
  using ::putchar;
  using ::puts;
  using ::remove;
  using ::rename;
  using ::rewind;
  using ::scanf;
  using ::setbuf;
  using ::setvbuf;
  using ::sprintf;
  using ::sscanf;
  using ::tmpfile;
  using ::tmpnam;
  using ::ungetc;
  using ::vfprintf;
  using ::vprintf;
  using ::vsprintf;
}
# 36
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 2
3

# 1 "/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr.h"
1 3
# 98
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr.h" 3
# 1
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 1 3
# 37
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 3
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 1 3 4
# 18
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
#pragma ident "@(#)pthread.h	1.26	98/04/12 SMI"




# 1 "/usr/include/sched.h" 1 3 4
# 11 "/usr/include/sched.h" 3 4
#pragma ident "@(#)sched.h	1.9	98/01/16 SMI"





extern "C" {


struct sched_param {
        int sched_priority;
        int sched_nicelim;
        int sched_nice;
        int sched_pad[6];



};
# 44 "/usr/include/sched.h" 3 4
int sched_getparam(pid_t pid, struct sched_param *param);
int sched_setparam(pid_t pid, const struct sched_param *param);
int sched_getscheduler(pid_t pid);
int sched_setscheduler(pid_t pid, int policy,
                const struct sched_param *param);
int sched_yield(void);
int sched_get_priority_max(int policy);
int sched_get_priority_min(int policy);
int sched_rr_get_interval(pid_t pid, struct timespec *interval);
# 65 "/usr/include/sched.h" 3 4
}
# 24
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 2 3 4



extern "C" {
# 103
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
typedef struct _cleanup {
        uintptr_t pthread_cleanup_pad[4];
} _cleanup_t;



void __pthread_cleanup_push(void (*routine)(void *), void *args,
                                        caddr_t fp, _cleanup_t *info);
void __pthread_cleanup_pop(int ex, _cleanup_t *info);
caddr_t _getfp(void);
# 137
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
extern int pthread_attr_init(pthread_attr_t *);
extern int pthread_attr_destroy(pthread_attr_t *);
extern int pthread_attr_setstacksize(pthread_attr_t *, size_t);
extern int pthread_attr_getstacksize(const pthread_attr_t *, size_t *);
extern int pthread_attr_setstackaddr(pthread_attr_t *, void *);
extern int pthread_attr_getstackaddr(const pthread_attr_t *, void **);
extern int pthread_attr_setdetachstate(pthread_attr_t *, int);
extern int pthread_attr_getdetachstate(const pthread_attr_t *, int *);
extern int pthread_attr_setscope(pthread_attr_t *, int);
extern int pthread_attr_getscope(const pthread_attr_t *, int *);
extern int pthread_attr_setinheritsched(pthread_attr_t *, int);
extern int pthread_attr_getinheritsched(const pthread_attr_t *, int *);
extern int pthread_attr_setschedpolicy(pthread_attr_t *, int);
extern int pthread_attr_getschedpolicy(const pthread_attr_t *, int *);
extern int pthread_attr_setschedparam(pthread_attr_t *,
                                        const struct sched_param *);
extern int pthread_attr_getschedparam(const pthread_attr_t *,
                                        struct sched_param *);
extern int pthread_create(pthread_t *, const pthread_attr_t *,
                                void * (*)(void *), void *);
extern int pthread_once(pthread_once_t *, void (*)(void));
extern int pthread_join(pthread_t, void **);
extern int pthread_detach(pthread_t);
extern void pthread_exit(void *);
extern int pthread_cancel(pthread_t);
extern int pthread_setschedparam(pthread_t, int, const struct
sched_param *);
extern int pthread_getschedparam(pthread_t, int *, struct sched_param
*);
extern int pthread_setcancelstate(int, int *);
extern int pthread_setcanceltype(int, int *);
extern void pthread_testcancel(void);
extern int pthread_equal(pthread_t, pthread_t);
extern int pthread_key_create(pthread_key_t *, void (*)(void *));
extern int pthread_key_delete(pthread_key_t);
extern int pthread_setspecific(pthread_key_t, const void *);
extern void *pthread_getspecific(pthread_key_t);
extern pthread_t pthread_self(void);




extern int pthread_mutexattr_init(pthread_mutexattr_t *);
extern int pthread_mutexattr_destroy(pthread_mutexattr_t *);
extern int pthread_mutexattr_setpshared(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_getpshared(const pthread_mutexattr_t *, int
*);
extern int pthread_mutexattr_setprotocol(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_getprotocol(const pthread_mutexattr_t *,
int *);
extern int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_getprioceiling(const pthread_mutexattr_t *,
int *);
extern int pthread_mutex_init(pthread_mutex_t *, const
pthread_mutexattr_t *);
extern int pthread_mutex_destroy(pthread_mutex_t *);
extern int pthread_mutex_lock(pthread_mutex_t *);
extern int pthread_mutex_unlock(pthread_mutex_t *);
extern int pthread_mutex_trylock(pthread_mutex_t *);
extern int pthread_mutex_setprioceiling(pthread_mutex_t *, int, int *);
extern int pthread_mutex_getprioceiling(pthread_mutex_t *, int *);
extern int pthread_condattr_init(pthread_condattr_t *);
extern int pthread_condattr_destroy(pthread_condattr_t *);
extern int pthread_condattr_setpshared(pthread_condattr_t *, int);
extern int pthread_condattr_getpshared(const pthread_condattr_t *, int
*);
extern int pthread_cond_init(pthread_cond_t *, const pthread_condattr_t
*);
extern int pthread_cond_destroy(pthread_cond_t *);
extern int pthread_cond_broadcast(pthread_cond_t *);
extern int pthread_cond_signal(pthread_cond_t *);
extern int pthread_cond_wait(pthread_cond_t *, pthread_mutex_t *);
extern int pthread_cond_timedwait(pthread_cond_t *, pthread_mutex_t *,
                                        const struct timespec *);
extern int pthread_attr_getguardsize(const pthread_attr_t *, size_t *);
extern int pthread_attr_setguardsize(pthread_attr_t *, size_t);
extern int pthread_getconcurrency(void);
extern int pthread_setconcurrency(int newval);
extern int pthread_mutexattr_settype(pthread_mutexattr_t *, int);
extern int pthread_mutexattr_gettype(const pthread_mutexattr_t *, int
*);
extern int pthread_rwlock_init(pthread_rwlock_t *,
                                const pthread_rwlockattr_t *);
extern int pthread_rwlock_destroy(pthread_rwlock_t *);
extern int pthread_rwlock_rdlock(pthread_rwlock_t *);
extern int pthread_rwlock_tryrdlock(pthread_rwlock_t *);
extern int pthread_rwlock_wrlock(pthread_rwlock_t *);
extern int pthread_rwlock_trywrlock(pthread_rwlock_t *);
extern int pthread_rwlock_unlock(pthread_rwlock_t *);
extern int pthread_rwlockattr_init(pthread_rwlockattr_t *);
extern int pthread_rwlockattr_destroy(pthread_rwlockattr_t *);
extern int pthread_rwlockattr_getpshared(const pthread_rwlockattr_t *,
int *);
extern int pthread_rwlockattr_setpshared(pthread_rwlockattr_t *, int);
# 312
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/pt
hread.h" 3 4
}
# 38
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 2 3

typedef pthread_key_t __gthread_key_t;
typedef pthread_once_t __gthread_once_t;
typedef pthread_mutex_t __gthread_mutex_t;






#pragma weak pthread_once
#pragma weak pthread_key_create
#pragma weak pthread_key_delete
#pragma weak pthread_getspecific
#pragma weak pthread_setspecific
#pragma weak pthread_create

#pragma weak pthread_mutex_lock
#pragma weak pthread_mutex_trylock
#pragma weak pthread_mutex_unlock
# 80
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 3
static inline int
__gthread_active_p (void)
{
  static void *const __gthread_active_ptr = (void *) &pthread_create;
  return __gthread_active_ptr != 0;
}
# 437
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr-defaul
t.h" 3
static inline int
__gthread_once (__gthread_once_t *once, void (*func) (void))
{
  if (__gthread_active_p ())
    return pthread_once (once, func);
  else
    return -1;
}

static inline int
__gthread_key_create (__gthread_key_t *key, void (*dtor) (void *))
{
  return pthread_key_create (key, dtor);
}

static inline int
__gthread_key_dtor (__gthread_key_t key, void *ptr)
{

  if (ptr)
    return pthread_setspecific (key, 0);
  else
    return 0;
}

static inline int
__gthread_key_delete (__gthread_key_t key)
{
  return pthread_key_delete (key);
}

static inline void *
__gthread_getspecific (__gthread_key_t key)
{
  return pthread_getspecific (key);
}

static inline int
__gthread_setspecific (__gthread_key_t key, const void *ptr)
{
  return pthread_setspecific (key, ptr);
}

static inline int
__gthread_mutex_lock (__gthread_mutex_t *mutex)
{
  if (__gthread_active_p ())
    return pthread_mutex_lock (mutex);
  else
    return 0;
}

static inline int
__gthread_mutex_trylock (__gthread_mutex_t *mutex)
{
  if (__gthread_active_p ())
    return pthread_mutex_trylock (mutex);
  else
    return 0;
}

static inline int
__gthread_mutex_unlock (__gthread_mutex_t *mutex)
{
  if (__gthread_active_p ())
    return pthread_mutex_unlock (mutex);
  else
    return 0;
}
# 99
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/gthr.h" 2 3
# 38
"/usr/local/fitools/include/g++-v3/sparc-sun-solaris2.7/bits/c++io.h" 2
3

namespace std
{

  typedef long streamoff;
  typedef ptrdiff_t streamsize;



  typedef fpos_t __c_streampos;

  typedef __gthread_mutex_t __c_lock;


  typedef FILE __c_file;


  struct __ios_flags
  {
    typedef short __int_type;

    static const __int_type _S_boolalpha = 0x0001;
    static const __int_type _S_dec = 0x0002;
    static const __int_type _S_fixed = 0x0004;
    static const __int_type _S_hex = 0x0008;
    static const __int_type _S_internal = 0x0010;
    static const __int_type _S_left = 0x0020;
    static const __int_type _S_oct = 0x0040;
    static const __int_type _S_right = 0x0080;
    static const __int_type _S_scientific = 0x0100;
    static const __int_type _S_showbase = 0x0200;
    static const __int_type _S_showpoint = 0x0400;
    static const __int_type _S_showpos = 0x0800;
    static const __int_type _S_skipws = 0x1000;
    static const __int_type _S_unitbuf = 0x2000;
    static const __int_type _S_uppercase = 0x4000;
    static const __int_type _S_adjustfield = 0x0020 | 0x0080 | 0x0010;
    static const __int_type _S_basefield = 0x0002 | 0x0040 | 0x0008;
    static const __int_type _S_floatfield = 0x0100 | 0x0004;


    static const __int_type _S_badbit = 0x01;
    static const __int_type _S_eofbit = 0x02;
    static const __int_type _S_failbit = 0x04;


    static const __int_type _S_app = 0x01;
    static const __int_type _S_ate = 0x02;
    static const __int_type _S_bin = 0x04;
    static const __int_type _S_in = 0x08;
    static const __int_type _S_out = 0x10;
    static const __int_type _S_trunc = 0x20;
  };
}
# 45 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/cwchar" 1 3
# 48 "/usr/local/fitools/include/g++-v3/cwchar" 3



# 1 "/usr/local/fitools/include/g++-v3/ctime" 1 3
# 48 "/usr/local/fitools/include/g++-v3/ctime" 3
# 64 "/usr/local/fitools/include/g++-v3/ctime" 3
namespace std
{
  using ::clock_t;
  using ::time_t;
  using ::tm;

  using ::clock;
  using ::difftime;
  using ::mktime;
  using ::time;
  using ::asctime;
  using ::ctime;
  using ::gmtime;
  using ::localtime;
  using ::strftime;
}
# 52 "/usr/local/fitools/include/g++-v3/cwchar" 2 3


# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 1 3 4
# 18
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
#pragma ident "@(#)wchar.h	1.31	98/05/04 SMI"




# 1 "/usr/include/wchar_impl.h" 1 3 4
# 9 "/usr/include/wchar_impl.h" 3 4
#pragma ident "@(#)wchar_impl.h	1.2	98/02/27 SMI"




extern "C" {



typedef struct {



        int __filler[6];

} __mbstate_t;



}
# 24
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 2 3 4
# 33
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
# 1 "/usr/include/ctype.h" 1 3 4
# 16 "/usr/include/ctype.h" 3 4
#pragma ident "@(#)ctype.h	1.30	98/01/16 SMI"




extern "C" {
# 48 "/usr/include/ctype.h" 3 4
extern int isalnum(int);
extern int isalpha(int);
extern int iscntrl(int);
extern int isdigit(int);
extern int isgraph(int);
extern int islower(int);
extern int isprint(int);
extern int ispunct(int);
extern int isspace(int);
extern int isupper(int);
extern int isxdigit(int);
extern int tolower(int);
extern int toupper(int);




extern int isascii(int);
extern int toascii(int);
extern int _tolower(int);
extern int _toupper(int);



extern unsigned char __ctype[];
extern unsigned int *__ctype_mask;
extern int *__trans_upper;
extern int *__trans_lower;
# 163 "/usr/include/ctype.h" 3 4
}
# 34
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 2 3 4
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/st
ddef.h" 1 3 4
# 35
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 2 3 4





extern "C" {
# 61
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
typedef long wint_t;





typedef int wctype_t;
# 103
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
typedef __mbstate_t mbstate_t;
# 113
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
extern int iswalpha(wint_t);
extern int iswupper(wint_t);
extern int iswlower(wint_t);
extern int iswdigit(wint_t);
extern int iswxdigit(wint_t);
extern int iswalnum(wint_t);
extern int iswspace(wint_t);
extern int iswpunct(wint_t);
extern int iswprint(wint_t);
extern int iswgraph(wint_t);
extern int iswcntrl(wint_t);
extern int iswctype(wint_t, wctype_t);
extern wint_t towlower(wint_t);
extern wint_t towupper(wint_t);
extern wint_t fgetwc(__FILE *);
extern wchar_t *fgetws(wchar_t *, int, __FILE *);
extern wint_t fputwc(wint_t, __FILE *);
extern int fputws(const wchar_t *, __FILE *);
extern wint_t ungetwc(wint_t, __FILE *);
extern wint_t getwc(__FILE *);
extern wint_t getwchar(void);
extern wint_t putwc(wint_t, __FILE *);
extern wint_t putwchar(wint_t);
extern double wcstod(const wchar_t *, wchar_t **);
extern long wcstol(const wchar_t *, wchar_t **, int);
extern unsigned long wcstoul(const wchar_t *, wchar_t **, int);
extern wchar_t *wcscat(wchar_t *, const wchar_t *);
extern wchar_t *wcschr(const wchar_t *, wchar_t);
extern int wcscmp(const wchar_t *, const wchar_t *);
extern int wcscoll(const wchar_t *, const wchar_t *);
extern wchar_t *wcscpy(wchar_t *, const wchar_t *);
extern size_t wcscspn(const wchar_t *, const wchar_t *);
extern size_t wcslen(const wchar_t *);
extern wchar_t *wcsncat(wchar_t *, const wchar_t *, size_t);
extern int wcsncmp(const wchar_t *, const wchar_t *, size_t);
extern wchar_t *wcsncpy(wchar_t *, const wchar_t *, size_t);
extern wchar_t *wcspbrk(const wchar_t *, const wchar_t *);
extern wchar_t *wcsrchr(const wchar_t *, wchar_t);
extern size_t wcsspn(const wchar_t *, const wchar_t *);
extern wchar_t *wcswcs(const wchar_t *, const wchar_t *);
extern int wcswidth(const wchar_t *, size_t);
extern size_t wcsxfrm(wchar_t *, const wchar_t *, size_t);
extern int wcwidth(const wchar_t);
extern wctype_t wctype(const char *);







extern wchar_t *wcstok(wchar_t *, const wchar_t *, wchar_t **);
extern size_t wcsftime(wchar_t *, size_t, const wchar_t *, const struct
tm *);
#pragma redefine_extname wcstok __wcstok_xpg5
#pragma redefine_extname wcsftime __wcsftime_xpg5
# 180
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
extern wint_t btowc(int);
extern int fwprintf(__FILE *, const wchar_t *, ...);
extern int fwscanf(__FILE *, const wchar_t *, ...);
extern int fwide(__FILE *, int);
extern int mbsinit(const mbstate_t *);
extern size_t mbrlen(const char *, size_t, mbstate_t *);
extern size_t mbrtowc(wchar_t *, const char *, size_t, mbstate_t *);
extern size_t mbsrtowcs(wchar_t *, const char **, size_t, mbstate_t *);
extern int swprintf(wchar_t *, size_t, const wchar_t *, ...);
extern int swscanf(const wchar_t *, const wchar_t *, ...);
extern int vfwprintf(__FILE *, const wchar_t *, __va_list);
extern int vwprintf(const wchar_t *, __va_list);
extern int vswprintf(wchar_t *, size_t, const wchar_t *, __va_list);
extern size_t wcrtomb(char *, wchar_t, mbstate_t *);
extern size_t wcsrtombs(char *, const wchar_t **, size_t, mbstate_t *);
extern wchar_t *wcsstr(const wchar_t *, const wchar_t *);
extern int wctob(wint_t);
extern wchar_t *wmemchr(const wchar_t *, wchar_t, size_t);
extern int wmemcmp(const wchar_t *, const wchar_t *, size_t);
extern wchar_t *wmemcpy(wchar_t *, const wchar_t *, size_t);
extern wchar_t *wmemmove(wchar_t *, const wchar_t *, size_t);
extern wchar_t *wmemset(wchar_t *, wchar_t, size_t);
extern int wprintf(const wchar_t *, ...);
extern int wscanf(const wchar_t *, ...);
# 307
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
#pragma redefine_extname fgetwc __fgetwc_xpg5
#pragma redefine_extname getwc __getwc_xpg5
#pragma redefine_extname getwchar __getwchar_xpg5
#pragma redefine_extname fputwc __fputwc_xpg5
#pragma redefine_extname putwc __putwc_xpg5
#pragma redefine_extname putwchar __putwchar_xpg5
#pragma redefine_extname fgetws __fgetws_xpg5
#pragma redefine_extname fputws __fputws_xpg5
#pragma redefine_extname ungetwc __ungetwc_xpg5
# 352
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/wc
har.h" 3 4
}
# 55 "/usr/local/fitools/include/g++-v3/cwchar" 2 3
# 69 "/usr/local/fitools/include/g++-v3/cwchar" 3
namespace std
{
  using ::mbstate_t;
}
# 46 "/usr/local/fitools/include/g++-v3/bits/fpos.h" 2 3

namespace std
{



  template<typename _StateT>
    class fpos
    {
    public:

      typedef _StateT __state_type;

    private:
      streamoff _M_off;
      __state_type _M_st;

    public:
      __state_type
      state() const { return _M_st; }

      void
      state(__state_type __st) { _M_st = __st; }



      fpos(): _M_off(streamoff()), _M_st(__state_type()) { }

      fpos(streamoff __off, __state_type __st = __state_type())
      : _M_off(__off), _M_st(__st) { }

      operator streamoff() const { return _M_off; }

      fpos&
      operator+=(streamoff __off) { _M_off += __off; return *this; }

      fpos&
      operator-=(streamoff __off) { _M_off -= __off; return *this; }

      fpos
      operator+(streamoff __off)
      {
        fpos __t(*this);
        __t += __off;
        return __t;
      }

      fpos
      operator-(streamoff __off)
      {
        fpos __t(*this);
        __t -= __off;
        return __t;
      }

      bool
      operator==(const fpos& __pos) const
      { return _M_off == __pos._M_off; }

      bool
      operator!=(const fpos& __pos) const
      { return _M_off != __pos._M_off; }

      streamoff
      _M_position() const { return _M_off; }

      void
      _M_position(streamoff __off) { _M_off = __off; }
    };


  typedef fpos<mbstate_t> streampos;



}
# 47 "/usr/local/fitools/include/g++-v3/iosfwd" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/functexcept.h" 1 3
# 34 "/usr/local/fitools/include/g++-v3/bits/functexcept.h" 3
# 1 "/usr/local/fitools/include/g++-v3/exception_defines.h" 1 3
# 35 "/usr/local/fitools/include/g++-v3/bits/functexcept.h" 2 3

namespace std
{

  void
  __throw_bad_exception(void);


  void
  __throw_bad_alloc(void);


  void
  __throw_bad_cast(void);

  void
  __throw_bad_typeid(void);


  void
  __throw_logic_error(const char* __s);

  void
  __throw_domain_error(const char* __s);

  void
  __throw_invalid_argument(const char* __s);

  void
  __throw_length_error(const char* __s);

  void
  __throw_out_of_range(const char* __s);

  void
  __throw_runtime_error(const char* __s);

  void
  __throw_range_error(const char* __s);

  void
  __throw_overflow_error(const char* __s);

  void
  __throw_underflow_error(const char* __s);


  void
  __throw_ios_failure(const char* __s);
}
# 48 "/usr/local/fitools/include/g++-v3/iosfwd" 2 3

namespace std
{
  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ios;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_streambuf;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_istream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ostream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_iostream;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
            typename _Alloc = allocator<_CharT> >
    class basic_stringbuf;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_istringstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_ostringstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT>,
           typename _Alloc = allocator<_CharT> >
    class basic_stringstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_filebuf;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ifstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_ofstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class basic_fstream;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class istreambuf_iterator;

  template<typename _CharT, typename _Traits = char_traits<_CharT> >
    class ostreambuf_iterator;



  class ios_base;


  typedef basic_ios<char> ios;
  typedef basic_streambuf<char> streambuf;
  typedef basic_istream<char> istream;
  typedef basic_ostream<char> ostream;
  typedef basic_iostream<char> iostream;
  typedef basic_stringbuf<char> stringbuf;
  typedef basic_istringstream<char> istringstream;
  typedef basic_ostringstream<char> ostringstream;
  typedef basic_stringstream<char> stringstream;
  typedef basic_filebuf<char> filebuf;
  typedef basic_ifstream<char> ifstream;
  typedef basic_ofstream<char> ofstream;
  typedef basic_fstream<char> fstream;

  typedef basic_ios<wchar_t> wios;
  typedef basic_streambuf<wchar_t> wstreambuf;
  typedef basic_istream<wchar_t> wistream;
  typedef basic_ostream<wchar_t> wostream;
  typedef basic_iostream<wchar_t> wiostream;
  typedef basic_stringbuf<wchar_t> wstringbuf;
  typedef basic_istringstream<wchar_t> wistringstream;
  typedef basic_ostringstream<wchar_t> wostringstream;
  typedef basic_stringstream<wchar_t> wstringstream;
  typedef basic_filebuf<wchar_t> wfilebuf;
  typedef basic_ifstream<wchar_t> wifstream;
  typedef basic_ofstream<wchar_t> wofstream;
  typedef basic_fstream<wchar_t> wfstream;
}
# 71 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_pair.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_pair.h" 3
namespace std
{


template <class _T1, class _T2>
struct pair {
  typedef _T1 first_type;
  typedef _T2 second_type;

  _T1 first;
  _T2 second;




  pair() : first(), second() {}




  pair(const _T1& __a, const _T2& __b) : first(__a), second(__b) {}


  template <class _U1, class _U2>
  pair(const pair<_U1, _U2>& __p) : first(__p.first), second(__p.second)
{}
};


template <class _T1, class _T2>
inline bool operator==(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y)
{
  return __x.first == __y.first && __x.second == __y.second;
}


template <class _T1, class _T2>
inline bool operator<(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y)
{
  return __x.first < __y.first ||
         (!(__y.first < __x.first) && __x.second < __y.second);
}


template <class _T1, class _T2>
inline bool operator!=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return !(__x == __y);
}


template <class _T1, class _T2>
inline bool operator>(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return __y < __x;
}


template <class _T1, class _T2>
inline bool operator<=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return !(__y < __x);
}


template <class _T1, class _T2>
inline bool operator>=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>&
__y) {
  return !(__x < __y);
}
# 140 "/usr/local/fitools/include/g++-v3/bits/stl_pair.h" 3
template <class _T1, class _T2>


inline pair<_T1, _T2> make_pair(_T1 __x, _T2 __y)



{
  return pair<_T1, _T2>(__x, __y);
}

}
# 72 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 1 3
# 53 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 3
# 90 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 3
struct __true_type {};
struct __false_type {};

template <class _Tp>
struct __type_traits {
   typedef __true_type this_dummy_member_must_be_first;
# 113 "/usr/local/fitools/include/g++-v3/bits/type_traits.h" 3
   typedef __false_type has_trivial_default_constructor;
   typedef __false_type has_trivial_copy_constructor;
   typedef __false_type has_trivial_assignment_operator;
   typedef __false_type has_trivial_destructor;
   typedef __false_type is_POD_type;
};




template<> struct __type_traits<bool> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<char> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<signed char> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned char> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<wchar_t> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<short> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned short> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<int> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned int> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<long long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<unsigned long long> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<float> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<double> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template<> struct __type_traits<long double> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};

template <class _Tp>
struct __type_traits<_Tp*> {
   typedef __true_type has_trivial_default_constructor;
   typedef __true_type has_trivial_copy_constructor;
   typedef __true_type has_trivial_assignment_operator;
   typedef __true_type has_trivial_destructor;
   typedef __true_type is_POD_type;
};





template <class _Tp> struct _Is_integer {
  typedef __false_type _Integral;
};

template<> struct _Is_integer<bool> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<char> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<signed char> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned char> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<wchar_t> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<short> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned short> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<int> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned int> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<long> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned long> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<long long> {
  typedef __true_type _Integral;
};

template<> struct _Is_integer<unsigned long long> {
  typedef __true_type _Integral;
};

template<typename _Tp> struct _Is_normal_iterator {
   typedef __false_type _Normal;
};


namespace __gnu_cxx
{
  template<typename _Iterator, typename _Container> class
__normal_iterator;
}

template<typename _Iterator, typename _Container>
struct _Is_normal_iterator< __gnu_cxx::__normal_iterator<_Iterator,
_Container> > {
   typedef __true_type _Normal;
};
# 73 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h" 1
3
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h"
3

namespace std
{
# 80 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h"
3
  struct input_iterator_tag {};

  struct output_iterator_tag {};

  struct forward_iterator_tag : public input_iterator_tag {};

  struct bidirectional_iterator_tag : public forward_iterator_tag {};

  struct random_access_iterator_tag : public bidirectional_iterator_tag
{};
# 100 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_types.h"
3
  template<typename _Category, typename _Tp, typename _Distance =
ptrdiff_t,
           typename _Pointer = _Tp*, typename _Reference = _Tp&>
    struct iterator {

      typedef _Category iterator_category;

      typedef _Tp value_type;

      typedef _Distance difference_type;

      typedef _Pointer pointer;

      typedef _Reference reference;
    };







  template<typename _Iterator>
    struct iterator_traits {
      typedef typename _Iterator::iterator_category iterator_category;
      typedef typename _Iterator::value_type value_type;
      typedef typename _Iterator::difference_type difference_type;
      typedef typename _Iterator::pointer pointer;
      typedef typename _Iterator::reference reference;
    };

  template<typename _Tp>
    struct iterator_traits<_Tp*> {
      typedef random_access_iterator_tag iterator_category;
      typedef _Tp value_type;
      typedef ptrdiff_t difference_type;
      typedef _Tp* pointer;
      typedef _Tp& reference;
    };

  template<typename _Tp>
    struct iterator_traits<const _Tp*> {
      typedef random_access_iterator_tag iterator_category;
      typedef _Tp value_type;
      typedef ptrdiff_t difference_type;
      typedef const _Tp* pointer;
      typedef const _Tp& reference;
    };







  template<typename _Iter>
    inline typename iterator_traits<_Iter>::iterator_category
    __iterator_category(const _Iter&)
    { return typename iterator_traits<_Iter>::iterator_category(); }

}
# 74 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h" 1
3
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
3
# 1 "/usr/local/fitools/include/g++-v3/bits/concept_check.h" 1 3
# 39 "/usr/local/fitools/include/g++-v3/bits/concept_check.h" 3
# 69 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
2 3




namespace std
{
template<typename _InputIterator>
  inline typename iterator_traits<_InputIterator>::difference_type
  __distance(_InputIterator __first, _InputIterator __last,
input_iterator_tag)
  {



    typename iterator_traits<_InputIterator>::difference_type __n = 0;
    while (__first != __last) {
      ++__first; ++__n;
    }
    return __n;
  }

template<typename _RandomAccessIterator>
  inline typename
iterator_traits<_RandomAccessIterator>::difference_type
  __distance(_RandomAccessIterator __first, _RandomAccessIterator
__last,
             random_access_iterator_tag)
  {


    return __last - __first;
  }
# 111 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
3
template<typename _InputIterator>
  inline typename iterator_traits<_InputIterator>::difference_type
  distance(_InputIterator __first, _InputIterator __last)
  {

    return __distance(__first, __last, __iterator_category(__first));
  }

template<typename _InputIter, typename _Distance>
  inline void
  __advance(_InputIter& __i, _Distance __n, input_iterator_tag)
  {


    while (__n--) ++__i;
  }

template<typename _BidirectionalIterator, typename _Distance>
  inline void
  __advance(_BidirectionalIterator& __i, _Distance __n,
            bidirectional_iterator_tag)
  {



    if (__n > 0)
      while (__n--) ++__i;
    else
      while (__n++) --__i;
  }

template<typename _RandomAccessIterator, typename _Distance>
  inline void
  __advance(_RandomAccessIterator& __i, _Distance __n,
            random_access_iterator_tag)
  {


    __i += __n;
  }
# 164 "/usr/local/fitools/include/g++-v3/bits/stl_iterator_base_funcs.h"
3
template<typename _InputIterator, typename _Distance>
  inline void
  advance(_InputIterator& __i, _Distance __n)
  {

    __advance(__i, __n, __iterator_category(__i));
  }

}
# 75 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 1 3
# 68 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
namespace std
{
# 89 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Iterator>
    class reverse_iterator
    : public iterator<typename
iterator_traits<_Iterator>::iterator_category,
                      typename iterator_traits<_Iterator>::value_type,
                      typename
iterator_traits<_Iterator>::difference_type,
                      typename iterator_traits<_Iterator>::pointer,
                      typename iterator_traits<_Iterator>::reference>
    {
    protected:
      _Iterator current;

    public:
      typedef _Iterator iterator_type;
      typedef typename iterator_traits<_Iterator>::difference_type

difference_type;
      typedef typename iterator_traits<_Iterator>::reference reference;
      typedef typename iterator_traits<_Iterator>::pointer pointer;

    public:



      reverse_iterator() { }




      explicit
      reverse_iterator(iterator_type __x) : current(__x) { }




      reverse_iterator(const reverse_iterator& __x)
      : current(__x.current) { }





      template<typename _Iter>
        reverse_iterator(const reverse_iterator<_Iter>& __x)
        : current(__x.base()) { }




      iterator_type
      base() const { return current; }






      reference
      operator*() const
      {
        _Iterator __tmp = current;
        return *--__tmp;
      }






      pointer
      operator->() const { return &(operator*()); }






      reverse_iterator&
      operator++()
      {
        --current;
        return *this;
      }






      reverse_iterator
      operator++(int)
      {
        reverse_iterator __tmp = *this;
        --current;
        return __tmp;
      }






      reverse_iterator&
      operator--()
      {
        ++current;
        return *this;
      }






      reverse_iterator operator--(int)
      {
        reverse_iterator __tmp = *this;
        ++current;
        return __tmp;
      }






      reverse_iterator
      operator+(difference_type __n) const
      { return reverse_iterator(current - __n); }






      reverse_iterator&
      operator+=(difference_type __n)
      {
        current -= __n;
        return *this;
      }






      reverse_iterator
      operator-(difference_type __n) const
      { return reverse_iterator(current + __n); }






      reverse_iterator&
      operator-=(difference_type __n)
      {
        current += __n;
        return *this;
      }






      reference
      operator[](difference_type __n) const { return *(*this + __n); }
    };
# 269 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Iterator>
    inline bool
    operator==(const reverse_iterator<_Iterator>& __x,
               const reverse_iterator<_Iterator>& __y)
    { return __x.base() == __y.base(); }

  template<typename _Iterator>
    inline bool
    operator<(const reverse_iterator<_Iterator>& __x,
              const reverse_iterator<_Iterator>& __y)
    { return __y.base() < __x.base(); }

  template<typename _Iterator>
    inline bool
    operator!=(const reverse_iterator<_Iterator>& __x,
               const reverse_iterator<_Iterator>& __y)
    { return !(__x == __y); }

  template<typename _Iterator>
    inline bool
    operator>(const reverse_iterator<_Iterator>& __x,
              const reverse_iterator<_Iterator>& __y)
    { return __y < __x; }

  template<typename _Iterator>
    inline bool
    operator<=(const reverse_iterator<_Iterator>& __x,
                const reverse_iterator<_Iterator>& __y)
    { return !(__y < __x); }

  template<typename _Iterator>
    inline bool
    operator>=(const reverse_iterator<_Iterator>& __x,
               const reverse_iterator<_Iterator>& __y)
    { return !(__x < __y); }

  template<typename _Iterator>
    inline typename reverse_iterator<_Iterator>::difference_type
    operator-(const reverse_iterator<_Iterator>& __x,
              const reverse_iterator<_Iterator>& __y)
    { return __y.base() - __x.base(); }

  template<typename _Iterator>
    inline reverse_iterator<_Iterator>
    operator+(typename reverse_iterator<_Iterator>::difference_type __n,
              const reverse_iterator<_Iterator>& __x)
    { return reverse_iterator<_Iterator>(__x.base() - __n); }
# 327 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    class back_insert_iterator
    : public iterator<output_iterator_tag, void, void, void, void>
    {
    protected:
      _Container* container;

    public:

      typedef _Container container_type;


      explicit
      back_insert_iterator(_Container& __x) : container(&__x) { }
# 353 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
      back_insert_iterator&
      operator=(typename _Container::const_reference __value)
      {
        container->push_back(__value);
        return *this;
      }


      back_insert_iterator&
      operator*() { return *this; }


      back_insert_iterator&
      operator++() { return *this; }


      back_insert_iterator
      operator++(int) { return *this; }
    };
# 384 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    inline back_insert_iterator<_Container>
    back_inserter(_Container& __x)
    { return back_insert_iterator<_Container>(__x); }
# 397 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    class front_insert_iterator
    : public iterator<output_iterator_tag, void, void, void, void>
    {
    protected:
      _Container* container;

    public:

      typedef _Container container_type;


      explicit front_insert_iterator(_Container& __x) : container(&__x)
{ }
# 422 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
      front_insert_iterator&
      operator=(typename _Container::const_reference __value)
      {
        container->push_front(__value);
        return *this;
      }


      front_insert_iterator&
      operator*() { return *this; }


      front_insert_iterator&
      operator++() { return *this; }


      front_insert_iterator
      operator++(int) { return *this; }
    };
# 453 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    inline front_insert_iterator<_Container>
    front_inserter(_Container& __x)
    { return front_insert_iterator<_Container>(__x); }
# 470 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container>
    class insert_iterator
    : public iterator<output_iterator_tag, void, void, void, void>
    {
    protected:
      _Container* container;
      typename _Container::iterator iter;

    public:

      typedef _Container container_type;





      insert_iterator(_Container& __x, typename _Container::iterator
__i)
      : container(&__x), iter(__i) {}
# 512 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
      insert_iterator&
      operator=(const typename _Container::const_reference __value)
      {
        iter = container->insert(iter, __value);
        ++iter;
        return *this;
      }


      insert_iterator&
      operator*() { return *this; }


      insert_iterator&
      operator++() { return *this; }


      insert_iterator&
      operator++(int) { return *this; }
    };
# 544 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _Container, typename _Iterator>
    inline insert_iterator<_Container>
    inserter(_Container& __x, _Iterator __i)
    {
      return insert_iterator<_Container>(__x,
                                         typename
_Container::iterator(__i));
    }
}

namespace __gnu_cxx
{







  using std::iterator_traits;
  using std::iterator;
  template<typename _Iterator, typename _Container>
    class __normal_iterator
      : public iterator<typename
iterator_traits<_Iterator>::iterator_category,
                        typename iterator_traits<_Iterator>::value_type,
                        typename
iterator_traits<_Iterator>::difference_type,
                        typename iterator_traits<_Iterator>::pointer,
                        typename iterator_traits<_Iterator>::reference>
    {
    protected:
      _Iterator _M_current;

    public:
      typedef typename iterator_traits<_Iterator>::difference_type

difference_type;
      typedef typename iterator_traits<_Iterator>::reference reference;
      typedef typename iterator_traits<_Iterator>::pointer pointer;

      __normal_iterator() : _M_current(_Iterator()) { }

      explicit
      __normal_iterator(const _Iterator& __i) : _M_current(__i) { }


      template<typename _Iter>
      inline __normal_iterator(const __normal_iterator<_Iter,
_Container>& __i)
        : _M_current(__i.base()) { }


      reference
      operator*() const { return *_M_current; }

      pointer
      operator->() const { return _M_current; }

      __normal_iterator&
      operator++() { ++_M_current; return *this; }

      __normal_iterator
      operator++(int) { return __normal_iterator(_M_current++); }


      __normal_iterator&
      operator--() { --_M_current; return *this; }

      __normal_iterator
      operator--(int) { return __normal_iterator(_M_current--); }


      reference
      operator[](const difference_type& __n) const
      { return _M_current[__n]; }

      __normal_iterator&
      operator+=(const difference_type& __n)
      { _M_current += __n; return *this; }

      __normal_iterator
      operator+(const difference_type& __n) const
      { return __normal_iterator(_M_current + __n); }

      __normal_iterator&
      operator-=(const difference_type& __n)
      { _M_current -= __n; return *this; }

      __normal_iterator
      operator-(const difference_type& __n) const
      { return __normal_iterator(_M_current - __n); }

      difference_type
      operator-(const __normal_iterator& __i) const
      { return _M_current - __i._M_current; }

      const _Iterator&
      base() const { return _M_current; }
    };
# 649 "/usr/local/fitools/include/g++-v3/bits/stl_iterator.h" 3
  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator==(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() == __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator==(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() == __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator!=(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() != __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator!=(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() != __rhs.base(); }


  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator<(const __normal_iterator<_IteratorL, _Container>& __lhs,
            const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() < __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator<(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() < __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator>(const __normal_iterator<_IteratorL, _Container>& __lhs,
            const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() > __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator>(const __normal_iterator<_Iterator, _Container>& __lhs,
            const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() > __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator<=(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() <= __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator<=(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() <= __rhs.base(); }

  template<typename _IteratorL, typename _IteratorR, typename
_Container>
  inline bool
  operator>=(const __normal_iterator<_IteratorL, _Container>& __lhs,
             const __normal_iterator<_IteratorR, _Container>& __rhs)
  { return __lhs.base() >= __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline bool
  operator>=(const __normal_iterator<_Iterator, _Container>& __lhs,
             const __normal_iterator<_Iterator, _Container>& __rhs)
  { return __lhs.base() >= __rhs.base(); }

  template<typename _Iterator, typename _Container>
  inline __normal_iterator<_Iterator, _Container>
  operator+(typename __normal_iterator<_Iterator,
_Container>::difference_type __n,
            const __normal_iterator<_Iterator, _Container>& __i)
  { return __normal_iterator<_Iterator, _Container>(__i.base() + __n); }
}
# 76 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 2 3


namespace std
{
# 91 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    inline void
    iter_swap(_ForwardIter1 __a, _ForwardIter2 __b)
    {
      typedef typename iterator_traits<_ForwardIter1>::value_type
_ValueType1;
      typedef typename iterator_traits<_ForwardIter2>::value_type
_ValueType2;







      _ValueType1 __tmp = *__a;
      *__a = *__b;
      *__b = __tmp;
    }
# 118 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp>
    inline void
    swap(_Tp& __a, _Tp& __b)
    {



      _Tp __tmp = __a;
      __a = __b;
      __b = __tmp;
    }
# 146 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp>
    inline const _Tp&
    min(const _Tp& __a, const _Tp& __b)
    {



      if (__b < __a) return __b; return __a;
    }
# 166 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp>
    inline const _Tp&
    max(const _Tp& __a, const _Tp& __b)
    {



      if (__a < __b) return __b; return __a;
    }
# 186 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp, typename _Compare>
    inline const _Tp&
    min(const _Tp& __a, const _Tp& __b, _Compare __comp)
    {

      if (__comp(__b, __a)) return __b; return __a;
    }
# 204 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _Tp, typename _Compare>
    inline const _Tp&
    max(const _Tp& __a, const _Tp& __b, _Compare __comp)
    {

      if (__comp(__a, __b)) return __b; return __a;
    }
# 221 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy(_InputIter __first, _InputIter __last,
           _OutputIter __result,
           input_iterator_tag)
    {
      for ( ; __first != __last; ++__result, ++__first)
        *__result = *__first;
      return __result;
    }

  template<typename _RandomAccessIter, typename _OutputIter>
    inline _OutputIter
    __copy(_RandomAccessIter __first, _RandomAccessIter __last,
           _OutputIter __result,
           random_access_iterator_tag)
    {
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type
          _Distance;
      for (_Distance __n = __last - __first; __n > 0; --__n) {
        *__result = *__first;
        ++__first;
        ++__result;
      }
      return __result;
    }

  template<typename _Tp>
    inline _Tp*
    __copy_trivial(const _Tp* __first, const _Tp* __last, _Tp* __result)
    {
      memmove(__result, __first, sizeof(_Tp) * (__last - __first));
      return __result + (__last - __first);
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_aux2(_InputIter __first, _InputIter __last,
                _OutputIter __result, __false_type)
    { return __copy(__first, __last, __result,
__iterator_category(__first)); }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_aux2(_InputIter __first, _InputIter __last,
                _OutputIter __result, __true_type)
    { return __copy(__first, __last, __result,
__iterator_category(__first)); }

  template<typename _Tp>
    inline _Tp*
    __copy_aux2(_Tp* __first, _Tp* __last,
                _Tp* __result, __true_type)
    { return __copy_trivial(__first, __last, __result); }

  template<typename _Tp>
    inline _Tp*
    __copy_aux2(const _Tp* __first, const _Tp* __last,
                _Tp* __result, __true_type)
    { return __copy_trivial(__first, __last, __result); }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni2(_InputIter __first, _InputIter __last,
               _OutputIter __result, __true_type)
    {
      typedef typename iterator_traits<_InputIter>::value_type
          _ValueType;
      typedef typename
__type_traits<_ValueType>::has_trivial_assignment_operator
          _Trivial;
      return _OutputIter(__copy_aux2(__first, __last,
                                     __result.base(),
                                     _Trivial()));
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni2(_InputIter __first, _InputIter __last,
               _OutputIter __result, __false_type)
    {
      typedef typename iterator_traits<_InputIter>::value_type
          _ValueType;
      typedef typename
__type_traits<_ValueType>::has_trivial_assignment_operator
          _Trivial;
      return __copy_aux2(__first, __last,
                         __result,
                         _Trivial());
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni1(_InputIter __first, _InputIter __last,
               _OutputIter __result, __true_type)
    {
      typedef typename _Is_normal_iterator<_OutputIter>::_Normal
__Normal;
      return __copy_ni2(__first.base(), __last.base(), __result,
__Normal());
    }

  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    __copy_ni1(_InputIter __first, _InputIter __last,
               _OutputIter __result, __false_type)
    {
      typedef typename _Is_normal_iterator<_OutputIter>::_Normal
__Normal;
      return __copy_ni2(__first, __last, __result, __Normal());
    }
# 339 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    copy(_InputIter __first, _InputIter __last, _OutputIter __result)
    {





       typedef typename _Is_normal_iterator<_InputIter>::_Normal
__Normal;
       return __copy_ni1(__first, __last, __result, __Normal());
    }




  template<typename _BidirectionalIter1, typename _BidirectionalIter2>
    inline _BidirectionalIter2
    __copy_backward(_BidirectionalIter1 __first, _BidirectionalIter1
__last,
                    _BidirectionalIter2 __result,
                    bidirectional_iterator_tag)
    {
      while (__first != __last)
        *--__result = *--__last;
      return __result;
    }

  template<typename _RandomAccessIter, typename _BidirectionalIter>
    inline _BidirectionalIter
    __copy_backward(_RandomAccessIter __first, _RandomAccessIter __last,
                    _BidirectionalIter __result,
                    random_access_iterator_tag)
    {
      typename iterator_traits<_RandomAccessIter>::difference_type __n;
      for (__n = __last - __first; __n > 0; --__n)
        *--__result = *--__last;
      return __result;
    }







  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BoolType>
    struct __copy_backward_dispatch
    {
      static _BidirectionalIter2
      copy(_BidirectionalIter1 __first, _BidirectionalIter1 __last,
           _BidirectionalIter2 __result)
      {
        return __copy_backward(__first, __last,
                               __result,
                               __iterator_category(__first));
      }
    };

  template<typename _Tp>
    struct __copy_backward_dispatch<_Tp*, _Tp*, __true_type>
    {
      static _Tp*
      copy(const _Tp* __first, const _Tp* __last, _Tp* __result)
      {
        const ptrdiff_t _Num = __last - __first;
        memmove(__result - _Num, __first, sizeof(_Tp) * _Num);
        return __result - _Num;
      }
    };

  template<typename _Tp>
    struct __copy_backward_dispatch<const _Tp*, _Tp*, __true_type>
    {
      static _Tp*
      copy(const _Tp* __first, const _Tp* __last, _Tp* __result)
      {
        return __copy_backward_dispatch<_Tp*, _Tp*, __true_type>
          ::copy(__first, __last, __result);
      }
    };

  template<typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_aux(_BI1 __first, _BI1 __last, _BI2 __result)
    {
      typedef typename __type_traits<typename
iterator_traits<_BI2>::value_type>
                            ::has_trivial_assignment_operator _Trivial;
      return __copy_backward_dispatch<_BI1, _BI2, _Trivial>
                  ::copy(__first, __last, __result);
    }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_output_normal_iterator(_BI1 __first, _BI1 __last,
                                           _BI2 __result, __true_type)
    { return _BI2(__copy_backward_aux(__first, __last,
__result.base())); }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_output_normal_iterator(_BI1 __first, _BI1 __last,
                                           _BI2 __result, __false_type)
    { return __copy_backward_aux(__first, __last, __result); }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_input_normal_iterator(_BI1 __first, _BI1 __last,
                                          _BI2 __result, __true_type)
    {
      typedef typename _Is_normal_iterator<_BI2>::_Normal __Normal;
      return __copy_backward_output_normal_iterator(__first.base(),
__last.base(),
                                                    __result,
__Normal());
    }

  template <typename _BI1, typename _BI2>
    inline _BI2
    __copy_backward_input_normal_iterator(_BI1 __first, _BI1 __last,
                                          _BI2 __result, __false_type)
    {
      typedef typename _Is_normal_iterator<_BI2>::_Normal __Normal;
      return __copy_backward_output_normal_iterator(__first, __last,
__result,
                                                    __Normal());
    }
# 477 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template <typename _BI1, typename _BI2>
    inline _BI2
    copy_backward(_BI1 __first, _BI1 __last, _BI2 __result)
    {







      typedef typename _Is_normal_iterator<_BI1>::_Normal __Normal;
      return __copy_backward_input_normal_iterator(__first, __last,
__result,
                                                   __Normal());
    }
# 509 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _ForwardIter, typename _Tp>
    void
    fill(_ForwardIter __first, _ForwardIter __last, const _Tp& __value)
    {



      for ( ; __first != __last; ++__first)
        *__first = __value;
    }
# 531 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _OutputIter, typename _Size, typename _Tp>
    _OutputIter
    fill_n(_OutputIter __first, _Size __n, const _Tp& __value)
    {



      for ( ; __n > 0; --__n, ++__first)
        *__first = __value;
      return __first;
    }



  inline void
  fill(unsigned char* __first, unsigned char* __last, const unsigned
char& __c)
  {
    unsigned char __tmp = __c;
    memset(__first, __tmp, __last - __first);
  }

  inline void
  fill(signed char* __first, signed char* __last, const signed char&
__c)
  {
    signed char __tmp = __c;
    memset(__first, static_cast<unsigned char>(__tmp), __last -
__first);
  }

  inline void
  fill(char* __first, char* __last, const char& __c)
  {
    char __tmp = __c;
    memset(__first, static_cast<unsigned char>(__tmp), __last -
__first);
  }

  template<typename _Size>
    inline unsigned char*
    fill_n(unsigned char* __first, _Size __n, const unsigned char& __c)
    {
      fill(__first, __first + __n, __c);
      return __first + __n;
    }

  template<typename _Size>
    inline signed char*
    fill_n(char* __first, _Size __n, const signed char& __c)
    {
      fill(__first, __first + __n, __c);
      return __first + __n;
    }

  template<typename _Size>
    inline char*
    fill_n(char* __first, _Size __n, const char& __c)
    {
      fill(__first, __first + __n, __c);
      return __first + __n;
    }
# 606 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2>
    pair<_InputIter1, _InputIter2>
    mismatch(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2)
    {








      while (__first1 != __last1 && *__first1 == *__first2) {
        ++__first1;
        ++__first2;
      }
      return pair<_InputIter1, _InputIter2>(__first1, __first2);
    }
# 640 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_BinaryPredicate>
    pair<_InputIter1, _InputIter2>
    mismatch(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2,
             _BinaryPredicate __binary_pred)
    {




      while (__first1 != __last1 && __binary_pred(*__first1, *__first2))
{
        ++__first1;
        ++__first2;
      }
      return pair<_InputIter1, _InputIter2>(__first1, __first2);
    }
# 668 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2>
    inline bool
    equal(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2)
    {







      for ( ; __first1 != __last1; ++__first1, ++__first2)
        if (!(*__first1 == *__first2))
          return false;
      return true;
    }
# 699 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_BinaryPredicate>
    inline bool
    equal(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2,
          _BinaryPredicate __binary_pred)
    {




      for ( ; __first1 != __last1; ++__first1, ++__first2)
        if (!__binary_pred(*__first1, *__first2))
          return false;
      return true;
    }
# 732 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2>
    bool
    lexicographical_compare(_InputIter1 __first1, _InputIter1 __last1,
                            _InputIter2 __first2, _InputIter2 __last2)
    {








      for ( ; __first1 != __last1 && __first2 != __last2
            ; ++__first1, ++__first2) {
        if (*__first1 < *__first2)
          return true;
        if (*__first2 < *__first1)
          return false;
      }
      return __first1 == __last1 && __first2 != __last2;
    }
# 767 "/usr/local/fitools/include/g++-v3/bits/stl_algobase.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_Compare>
    bool
    lexicographical_compare(_InputIter1 __first1, _InputIter1 __last1,
                            _InputIter2 __first2, _InputIter2 __last2,
                            _Compare __comp)
    {




      for ( ; __first1 != __last1 && __first2 != __last2
            ; ++__first1, ++__first2) {
        if (__comp(*__first1, *__first2))
          return true;
        if (__comp(*__first2, *__first1))
          return false;
      }
      return __first1 == __last1 && __first2 != __last2;
    }

  inline bool
  lexicographical_compare(const unsigned char* __first1, const unsigned
char* __last1,
                          const unsigned char* __first2, const unsigned
char* __last2)
  {
    const size_t __len1 = __last1 - __first1;
    const size_t __len2 = __last2 - __first2;
    const int __result = memcmp(__first1, __first2, min(__len1,
__len2));
    return __result != 0 ? __result < 0 : __len1 < __len2;
  }

  inline bool
  lexicographical_compare(const char* __first1, const char* __last1,
                          const char* __first2, const char* __last2)
  {

    return lexicographical_compare((const signed char*) __first1,
                                   (const signed char*) __last1,
                                   (const signed char*) __first2,
                                   (const signed char*) __last2);






  }

}
# 67 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 1 3
# 67 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
namespace std
{






  template <class _T1, class _T2>
    inline void
    _Construct(_T1* __p, const _T2& __value)
    { new (static_cast<void*>(__p)) _T1(__value); }







  template <class _T1>
    inline void
    _Construct(_T1* __p)
    { new (static_cast<void*>(__p)) _T1(); }
# 98 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
  template <class _ForwardIterator>
    inline void
    __destroy_aux(_ForwardIterator __first, _ForwardIterator __last,
__false_type)
    { for ( ; __first != __last; ++__first) _Destroy(&*__first); }
# 112 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
  template <class _ForwardIterator>
    inline void
    __destroy_aux(_ForwardIterator, _ForwardIterator, __true_type)
    { }






  template <class _Tp>
    inline void
    _Destroy(_Tp* __pointer)
    { __pointer->~_Tp(); }
# 134 "/usr/local/fitools/include/g++-v3/bits/stl_construct.h" 3
  template <class _ForwardIterator>
    inline void
    _Destroy(_ForwardIterator __first, _ForwardIterator __last)
    {
      typedef typename iterator_traits<_ForwardIterator>::value_type
                       _Value_type;
      typedef typename
__type_traits<_Value_type>::has_trivial_destructor
                       _Has_trivial_destructor;

      __destroy_aux(__first, __last, _Has_trivial_destructor());
    }
}
# 68 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 1 3
# 66 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
namespace std
{



  template<typename _InputIter, typename _ForwardIter>
    inline _ForwardIter
    __uninitialized_copy_aux(_InputIter __first, _InputIter __last,
                             _ForwardIter __result,
                             __true_type)
    { return copy(__first, __last, __result); }

  template<typename _InputIter, typename _ForwardIter>
    _ForwardIter
    __uninitialized_copy_aux(_InputIter __first, _InputIter __last,
                             _ForwardIter __result,
                             __false_type)
    {
      _ForwardIter __cur = __result;
      try {
        for ( ; __first != __last; ++__first, ++__cur)
          _Construct(&*__cur, *__first);
        return __cur;
      }
      catch(...)
        {
          _Destroy(__result, __cur);
          throw;
        }
    }
# 106 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _InputIter, typename _ForwardIter>
    inline _ForwardIter
    uninitialized_copy(_InputIter __first, _InputIter __last,
_ForwardIter __result)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename __type_traits<_ValueType>::is_POD_type _Is_POD;
      return __uninitialized_copy_aux(__first, __last, __result,
_Is_POD());
    }

  inline char*
  uninitialized_copy(const char* __first, const char* __last, char*
__result)
  {
    memmove(__result, __first, __last - __first);
    return __result + (__last - __first);
  }

  inline wchar_t*
  uninitialized_copy(const wchar_t* __first, const wchar_t* __last,
                     wchar_t* __result)
  {
    memmove(__result, __first, sizeof(wchar_t) * (__last - __first));
    return __result + (__last - __first);
  }



  template<typename _ForwardIter, typename _Tp>
    inline void
    __uninitialized_fill_aux(_ForwardIter __first, _ForwardIter __last,
                             const _Tp& __x, __true_type)
    { fill(__first, __last, __x); }

  template<typename _ForwardIter, typename _Tp>
    void
    __uninitialized_fill_aux(_ForwardIter __first, _ForwardIter __last,
                             const _Tp& __x, __false_type)
    {
      _ForwardIter __cur = __first;
      try {
        for ( ; __cur != __last; ++__cur)
          _Construct(&*__cur, __x);
      }
      catch(...)
        {
          _Destroy(__first, __cur);
          throw;
        }
    }
# 164 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _ForwardIter, typename _Tp>
    inline void
    uninitialized_fill(_ForwardIter __first, _ForwardIter __last, const
_Tp& __x)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename __type_traits<_ValueType>::is_POD_type _Is_POD;
      __uninitialized_fill_aux(__first, __last, __x, _Is_POD());
    }



  template<typename _ForwardIter, typename _Size, typename _Tp>
    inline _ForwardIter
    __uninitialized_fill_n_aux(_ForwardIter __first, _Size __n,
                               const _Tp& __x, __true_type)
    {
      return fill_n(__first, __n, __x);
    }

  template<typename _ForwardIter, typename _Size, typename _Tp>
    _ForwardIter
    __uninitialized_fill_n_aux(_ForwardIter __first, _Size __n,
                               const _Tp& __x, __false_type)
    {
      _ForwardIter __cur = __first;
      try {
        for ( ; __n > 0; --__n, ++__cur)
          _Construct(&*__cur, __x);
        return __cur;
      }
      catch(...)
        {
          _Destroy(__first, __cur);
          throw;
        }
    }
# 210 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _ForwardIter, typename _Size, typename _Tp>
    inline _ForwardIter
    uninitialized_fill_n(_ForwardIter __first, _Size __n, const _Tp&
__x)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename __type_traits<_ValueType>::is_POD_type _Is_POD;
      return __uninitialized_fill_n_aux(__first, __n, __x, _Is_POD());
    }
# 227 "/usr/local/fitools/include/g++-v3/bits/stl_uninitialized.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_ForwardIter>
    inline _ForwardIter
    __uninitialized_copy_copy(_InputIter1 __first1, _InputIter1 __last1,
                              _InputIter2 __first2, _InputIter2 __last2,
                              _ForwardIter __result)
    {
      _ForwardIter __mid = uninitialized_copy(__first1, __last1,
__result);
      try {
        return uninitialized_copy(__first2, __last2, __mid);
      }
      catch(...)
        {
          _Destroy(__result, __mid);
          throw;
        }
    }




  template<typename _ForwardIter, typename _Tp, typename _InputIter>
    inline _ForwardIter
    __uninitialized_fill_copy(_ForwardIter __result, _ForwardIter __mid,
                              const _Tp& __x,
                              _InputIter __first, _InputIter __last)
    {
      uninitialized_fill(__result, __mid, __x);
      try {
        return uninitialized_copy(__first, __last, __mid);
      }
      catch(...)
        {
          _Destroy(__result, __mid);
          throw;
        }
    }




  template<typename _InputIter, typename _ForwardIter, typename _Tp>
    inline void
    __uninitialized_copy_fill(_InputIter __first1, _InputIter __last1,
                              _ForwardIter __first2, _ForwardIter
__last2,
                              const _Tp& __x)
    {
      _ForwardIter __mid2 = uninitialized_copy(__first1, __last1,
__first2);
      try {
        uninitialized_fill(__mid2, __last2, __x);
      }
      catch(...)
        {
          _Destroy(__first2, __mid2);
          throw;
        }
    }

}
# 69 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_heap.h" 1 3
# 63 "/usr/local/fitools/include/g++-v3/bits/stl_heap.h" 3
namespace std
{



  template<typename _RandomAccessIterator, typename _Distance, typename
_Tp>
    void
    __push_heap(_RandomAccessIterator __first,
                _Distance __holeIndex, _Distance __topIndex, _Tp
__value)
    {
      _Distance __parent = (__holeIndex - 1) / 2;
      while (__holeIndex > __topIndex && *(__first + __parent) <
__value) {
        *(__first + __holeIndex) = *(__first + __parent);
        __holeIndex = __parent;
        __parent = (__holeIndex - 1) / 2;
      }
      *(__first + __holeIndex) = __value;
    }

  template<typename _RandomAccessIterator>
    inline void
    push_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;






      __push_heap(__first, _DistanceType((__last - __first) - 1),
_DistanceType(0),
                  _ValueType(*(__last - 1)));
    }

  template<typename _RandomAccessIterator, typename _Distance, typename
_Tp,
            typename _Compare>
    void
    __push_heap(_RandomAccessIterator __first, _Distance __holeIndex,
                _Distance __topIndex, _Tp __value, _Compare __comp)
    {
      _Distance __parent = (__holeIndex - 1) / 2;
      while (__holeIndex > __topIndex && __comp(*(__first + __parent),
__value)) {
        *(__first + __holeIndex) = *(__first + __parent);
        __holeIndex = __parent;
        __parent = (__holeIndex - 1) / 2;
      }
      *(__first + __holeIndex) = __value;
    }

  template<typename _RandomAccessIterator, typename _Compare>
    inline void
    push_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
              _Compare __comp)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;





      __push_heap(__first, _DistanceType((__last - __first) - 1),
_DistanceType(0),
                  _ValueType(*(__last - 1)), __comp);
    }

  template<typename _RandomAccessIterator, typename _Distance, typename
_Tp>
    void
    __adjust_heap(_RandomAccessIterator __first, _Distance __holeIndex,
                  _Distance __len, _Tp __value)
    {
      _Distance __topIndex = __holeIndex;
      _Distance __secondChild = 2 * __holeIndex + 2;
      while (__secondChild < __len) {
        if (*(__first + __secondChild) < *(__first + (__secondChild -
1)))
          __secondChild--;
        *(__first + __holeIndex) = *(__first + __secondChild);
        __holeIndex = __secondChild;
        __secondChild = 2 * (__secondChild + 1);
      }
      if (__secondChild == __len) {
        *(__first + __holeIndex) = *(__first + (__secondChild - 1));
        __holeIndex = __secondChild - 1;
      }
      __push_heap(__first, __holeIndex, __topIndex, __value);
    }

  template<typename _RandomAccessIterator, typename _Tp>
    inline void
    __pop_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
               _RandomAccessIterator __result, _Tp __value)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type _Distance;
      *__result = *__first;
      __adjust_heap(__first, _Distance(0), _Distance(__last - __first),
__value);
    }

  template<typename _RandomAccessIterator>
    inline void
    pop_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type _ValueType;






      __pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last -
1)));
    }

  template<typename _RandomAccessIterator, typename _Distance,
           typename _Tp, typename _Compare>
    void
    __adjust_heap(_RandomAccessIterator __first, _Distance __holeIndex,
                  _Distance __len, _Tp __value, _Compare __comp)
    {
      _Distance __topIndex = __holeIndex;
      _Distance __secondChild = 2 * __holeIndex + 2;
      while (__secondChild < __len) {
        if (__comp(*(__first + __secondChild), *(__first +
(__secondChild - 1))))
          __secondChild--;
        *(__first + __holeIndex) = *(__first + __secondChild);
        __holeIndex = __secondChild;
        __secondChild = 2 * (__secondChild + 1);
      }
      if (__secondChild == __len) {
        *(__first + __holeIndex) = *(__first + (__secondChild - 1));
        __holeIndex = __secondChild - 1;
      }
      __push_heap(__first, __holeIndex, __topIndex, __value, __comp);
    }

  template<typename _RandomAccessIterator, typename _Tp, typename
_Compare>
    inline void
    __pop_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
               _RandomAccessIterator __result, _Tp __value, _Compare
__comp)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type _Distance;
      *__result = *__first;
      __adjust_heap(__first, _Distance(0), _Distance(__last - __first),
                    __value, __comp);
    }

  template<typename _RandomAccessIterator, typename _Compare>
    inline void
    pop_heap(_RandomAccessIterator __first,
             _RandomAccessIterator __last, _Compare __comp)
    {




      typedef typename
iterator_traits<_RandomAccessIterator>::value_type _ValueType;
      __pop_heap(__first, __last - 1, __last - 1, _ValueType(*(__last -
1)), __comp);
    }

  template<typename _RandomAccessIterator>
    void
    make_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;






      if (__last - __first < 2) return;
      _DistanceType __len = __last - __first;
      _DistanceType __parent = (__len - 2)/2;

      while (true) {
        __adjust_heap(__first, __parent, __len, _ValueType(*(__first +
__parent)));
        if (__parent == 0) return;
        __parent--;
      }
    }

  template<typename _RandomAccessIterator, typename _Compare>
    inline void
    make_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
              _Compare __comp)
    {
      typedef typename
iterator_traits<_RandomAccessIterator>::value_type
          _ValueType;
      typedef typename
iterator_traits<_RandomAccessIterator>::difference_type
          _DistanceType;





      if (__last - __first < 2) return;
      _DistanceType __len = __last - __first;
      _DistanceType __parent = (__len - 2)/2;

      while (true) {
        __adjust_heap(__first, __parent, __len,
                      _ValueType(*(__first + __parent)), __comp);
        if (__parent == 0) return;
        __parent--;
      }
    }

  template<typename _RandomAccessIterator>
    void
    sort_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last)
    {






      while (__last - __first > 1)
        pop_heap(__first, __last--);
    }

  template<typename _RandomAccessIterator, typename _Compare>
    void
    sort_heap(_RandomAccessIterator __first, _RandomAccessIterator
__last,
              _Compare __comp)
    {




      while (__last - __first > 1)
        pop_heap(__first, __last--, __comp);
    }

}
# 65 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 2 3
# 1 "/usr/local/fitools/include/g++-v3/bits/stl_tempbuf.h" 1 3
# 64 "/usr/local/fitools/include/g++-v3/bits/stl_tempbuf.h" 3
namespace std
{
# 74 "/usr/local/fitools/include/g++-v3/bits/stl_tempbuf.h" 3
template <class _ForwardIterator, class _Tp>
  class _Temporary_buffer
{



  ptrdiff_t _M_original_len;
  ptrdiff_t _M_len;
  _Tp* _M_buffer;


  void _M_allocate_buffer() {
    _M_original_len = _M_len;
    _M_buffer = 0;

    if (_M_len > (ptrdiff_t)(2147483647 / sizeof(_Tp)))
      _M_len = 2147483647 / sizeof(_Tp);

    while (_M_len > 0) {
      _M_buffer = (_Tp*) malloc(_M_len * sizeof(_Tp));
      if (_M_buffer)
        break;
      _M_len /= 2;
    }
  }

  void _M_initialize_buffer(const _Tp&, __true_type) {}
  void _M_initialize_buffer(const _Tp& val, __false_type) {
    uninitialized_fill_n(_M_buffer, _M_len, val);
  }

public:

  ptrdiff_t size() const { return _M_len; }

  ptrdiff_t requested_size() const { return _M_original_len; }

  _Tp* begin() { return _M_buffer; }

  _Tp* end() { return _M_buffer + _M_len; }

  _Temporary_buffer(_ForwardIterator __first, _ForwardIterator __last) {

    typedef typename __type_traits<_Tp>::has_trivial_default_constructor
            _Trivial;

    try {
      _M_len = distance(__first, __last);
      _M_allocate_buffer();
      if (_M_len > 0)
        _M_initialize_buffer(*__first, _Trivial());
    }
    catch(...)
      {
        free(_M_buffer);
        _M_buffer = 0;
        _M_len = 0;
        throw;
      }
  }

  ~_Temporary_buffer() {
    _Destroy(_M_buffer, _M_buffer + _M_len);
    free(_M_buffer);
  }

private:

  _Temporary_buffer(const _Temporary_buffer&) {}
  void operator=(const _Temporary_buffer&) {}
};

}
# 66 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 2 3



namespace std
{
# 84 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _Tp>
  inline const _Tp&
    __median(const _Tp& __a, const _Tp& __b, const _Tp& __c)
    {


      if (__a < __b)
        if (__b < __c)
          return __b;
        else if (__a < __c)
          return __c;
        else
          return __a;
      else if (__a < __c)
        return __a;
      else if (__b < __c)
        return __c;
      else
        return __b;
    }
# 118 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _Tp, typename _Compare>
    inline const _Tp&
    __median(const _Tp& __a, const _Tp& __b, const _Tp& __c, _Compare
__comp)
    {


      if (__comp(__a, __b))
        if (__comp(__b, __c))
          return __b;
        else if (__comp(__a, __c))
          return __c;
        else
          return __a;
      else if (__comp(__a, __c))
        return __a;
      else if (__comp(__b, __c))
        return __c;
      else
        return __b;
    }
# 150 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Function>
    _Function
    for_each(_InputIter __first, _InputIter __last, _Function __f)
    {


      for ( ; __first != __last; ++__first)
        __f(*__first);
      return __f;
    }






  template<typename _InputIter, typename _Tp>
    inline _InputIter
    find(_InputIter __first, _InputIter __last,
         const _Tp& __val,
         input_iterator_tag)
    {
      while (__first != __last && !(*__first == __val))
        ++__first;
      return __first;
    }






  template<typename _InputIter, typename _Predicate>
    inline _InputIter
    find_if(_InputIter __first, _InputIter __last,
            _Predicate __pred,
            input_iterator_tag)
    {
      while (__first != __last && !__pred(*__first))
        ++__first;
      return __first;
    }






  template<typename _RandomAccessIter, typename _Tp>
    _RandomAccessIter
    find(_RandomAccessIter __first, _RandomAccessIter __last,
         const _Tp& __val,
         random_access_iterator_tag)
    {
      typename iterator_traits<_RandomAccessIter>::difference_type
__trip_count
        = (__last - __first) >> 2;

      for ( ; __trip_count > 0 ; --__trip_count) {
        if (*__first == __val) return __first;
        ++__first;

        if (*__first == __val) return __first;
        ++__first;

        if (*__first == __val) return __first;
        ++__first;

        if (*__first == __val) return __first;
        ++__first;
      }

      switch(__last - __first) {
      case 3:
        if (*__first == __val) return __first;
        ++__first;
      case 2:
        if (*__first == __val) return __first;
        ++__first;
      case 1:
        if (*__first == __val) return __first;
        ++__first;
      case 0:
      default:
        return __last;
      }
    }






  template<typename _RandomAccessIter, typename _Predicate>
    _RandomAccessIter
    find_if(_RandomAccessIter __first, _RandomAccessIter __last,
            _Predicate __pred,
            random_access_iterator_tag)
    {
      typename iterator_traits<_RandomAccessIter>::difference_type
__trip_count
        = (__last - __first) >> 2;

      for ( ; __trip_count > 0 ; --__trip_count) {
        if (__pred(*__first)) return __first;
        ++__first;

        if (__pred(*__first)) return __first;
        ++__first;

        if (__pred(*__first)) return __first;
        ++__first;

        if (__pred(*__first)) return __first;
        ++__first;
      }

      switch(__last - __first) {
      case 3:
        if (__pred(*__first)) return __first;
        ++__first;
      case 2:
        if (__pred(*__first)) return __first;
        ++__first;
      case 1:
        if (__pred(*__first)) return __first;
        ++__first;
      case 0:
      default:
        return __last;
      }
    }
# 289 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Tp>
    inline _InputIter
    find(_InputIter __first, _InputIter __last,
         const _Tp& __val)
    {




      return find(__first, __last, __val, __iterator_category(__first));
    }
# 309 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Predicate>
    inline _InputIter
    find_if(_InputIter __first, _InputIter __last,
            _Predicate __pred)
    {




      return find_if(__first, __last, __pred,
__iterator_category(__first));
    }
# 329 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter>
    _ForwardIter
    adjacent_find(_ForwardIter __first, _ForwardIter __last)
    {




      if (__first == __last)
        return __last;
      _ForwardIter __next = __first;
      while(++__next != __last) {
        if (*__first == *__next)
          return __first;
        __first = __next;
      }
      return __last;
    }
# 358 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _BinaryPredicate>
    _ForwardIter
    adjacent_find(_ForwardIter __first, _ForwardIter __last,
                  _BinaryPredicate __binary_pred)
    {





      if (__first == __last)
        return __last;
      _ForwardIter __next = __first;
      while(++__next != __last) {
        if (__binary_pred(*__first, *__next))
          return __first;
        __first = __next;
      }
      return __last;
    }
# 387 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Tp>
    typename iterator_traits<_InputIter>::difference_type
    count(_InputIter __first, _InputIter __last, const _Tp& __value)
    {





      typename iterator_traits<_InputIter>::difference_type __n = 0;
      for ( ; __first != __last; ++__first)
        if (*__first == __value)
          ++__n;
      return __n;
    }
# 411 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _Predicate>
    typename iterator_traits<_InputIter>::difference_type
    count_if(_InputIter __first, _InputIter __last, _Predicate __pred)
    {




      typename iterator_traits<_InputIter>::difference_type __n = 0;
      for ( ; __first != __last; ++__first)
        if (__pred(*__first))
          ++__n;
      return __n;
    }
# 450 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    _ForwardIter1
    search(_ForwardIter1 __first1, _ForwardIter1 __last1,
           _ForwardIter2 __first2, _ForwardIter2 __last2)
    {








      if (__first1 == __last1 || __first2 == __last2)
        return __first1;


      _ForwardIter2 __tmp(__first2);
      ++__tmp;
      if (__tmp == __last2)
        return find(__first1, __last1, *__first2);



      _ForwardIter2 __p1, __p;

      __p1 = __first2; ++__p1;

      _ForwardIter1 __current = __first1;

      while (__first1 != __last1) {
        __first1 = find(__first1, __last1, *__first2);
        if (__first1 == __last1)
          return __last1;

        __p = __p1;
        __current = __first1;
        if (++__current == __last1)
          return __last1;

        while (*__current == *__p) {
          if (++__p == __last2)
            return __first1;
          if (++__current == __last1)
            return __last1;
        }

        ++__first1;
      }
      return __first1;
    }
# 522 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2, typename
_BinaryPred>
    _ForwardIter1
    search(_ForwardIter1 __first1, _ForwardIter1 __last1,
           _ForwardIter2 __first2, _ForwardIter2 __last2,
           _BinaryPred __predicate)
    {








      if (__first1 == __last1 || __first2 == __last2)
        return __first1;


      _ForwardIter2 __tmp(__first2);
      ++__tmp;
      if (__tmp == __last2) {
        while (__first1 != __last1 && !__predicate(*__first1,
*__first2))
          ++__first1;
        return __first1;
      }



      _ForwardIter2 __p1, __p;

      __p1 = __first2; ++__p1;

      _ForwardIter1 __current = __first1;

      while (__first1 != __last1) {
        while (__first1 != __last1) {
          if (__predicate(*__first1, *__first2))
            break;
          ++__first1;
        }
        while (__first1 != __last1 && !__predicate(*__first1,
*__first2))
          ++__first1;
        if (__first1 == __last1)
          return __last1;

        __p = __p1;
        __current = __first1;
        if (++__current == __last1) return __last1;

        while (__predicate(*__current, *__p)) {
          if (++__p == __last2)
            return __first1;
          if (++__current == __last1)
            return __last1;
        }

        ++__first1;
      }
      return __first1;
    }
# 596 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Integer, typename _Tp>
    _ForwardIter
    search_n(_ForwardIter __first, _ForwardIter __last,
             _Integer __count, const _Tp& __val)
    {






      if (__count <= 0)
        return __first;
      else {
        __first = find(__first, __last, __val);
        while (__first != __last) {
          _Integer __n = __count - 1;
          _ForwardIter __i = __first;
          ++__i;
          while (__i != __last && __n != 0 && *__i == __val) {
            ++__i;
            --__n;
          }
          if (__n == 0)
            return __first;
          else
            __first = find(__i, __last, __val);
        }
        return __last;
      }
    }
# 643 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Integer, typename _Tp,
           typename _BinaryPred>
    _ForwardIter
    search_n(_ForwardIter __first, _ForwardIter __last,
             _Integer __count, const _Tp& __val,
             _BinaryPred __binary_pred)
    {





      if (__count <= 0)
        return __first;
      else {
        while (__first != __last) {
          if (__binary_pred(*__first, __val))
            break;
          ++__first;
        }
        while (__first != __last) {
          _Integer __n = __count - 1;
          _ForwardIter __i = __first;
          ++__i;
          while (__i != __last && __n != 0 && __binary_pred(*__i,
__val)) {
            ++__i;
            --__n;
          }
          if (__n == 0)
            return __first;
          else {
            while (__i != __last) {
              if (__binary_pred(*__i, __val))
                break;
              ++__i;
            }
            __first = __i;
          }
        }
        return __last;
      }
    }
# 697 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    _ForwardIter2
    swap_ranges(_ForwardIter1 __first1, _ForwardIter1 __last1,
                _ForwardIter2 __first2)
    {










      for ( ; __first1 != __last1; ++__first1, ++__first2)
        iter_swap(__first1, __first2);
      return __first2;
    }
# 732 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_UnaryOperation>
    _OutputIter
    transform(_InputIter __first, _InputIter __last,
              _OutputIter __result, _UnaryOperation __unary_op)
    {






      for ( ; __first != __last; ++__first, ++__result)
        *__result = __unary_op(*__first);
      return __result;
    }
# 765 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _BinaryOperation>
    _OutputIter
    transform(_InputIter1 __first1, _InputIter1 __last1,
              _InputIter2 __first2, _OutputIter __result,
              _BinaryOperation __binary_op)
    {







      for ( ; __first1 != __last1; ++__first1, ++__first2, ++__result)
        *__result = __binary_op(*__first1, *__first2);
      return __result;
    }
# 796 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    void
    replace(_ForwardIter __first, _ForwardIter __last,
            const _Tp& __old_value, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first)
        if (*__first == __old_value)
          *__first = __new_value;
    }
# 825 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate, typename _Tp>
    void
    replace_if(_ForwardIter __first, _ForwardIter __last,
               _Predicate __pred, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first)
        if (__pred(*__first))
          *__first = __new_value;
    }
# 856 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename _Tp>
    _OutputIter
    replace_copy(_InputIter __first, _InputIter __last,
                 _OutputIter __result,
                 const _Tp& __old_value, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first, ++__result)
        *__result = *__first == __old_value ? __new_value : *__first;
      return __result;
    }
# 888 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_Predicate,
           typename _Tp>
    _OutputIter
    replace_copy_if(_InputIter __first, _InputIter __last,
                    _OutputIter __result,
                    _Predicate __pred, const _Tp& __new_value)
    {







      for ( ; __first != __last; ++__first, ++__result)
        *__result = __pred(*__first) ? __new_value : *__first;
      return __result;
    }
# 918 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Generator>
    void
    generate(_ForwardIter __first, _ForwardIter __last, _Generator
__gen)
    {





      for ( ; __first != __last; ++__first)
        *__first = __gen();
    }
# 942 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _OutputIter, typename _Size, typename _Generator>
    _OutputIter
    generate_n(_OutputIter __first, _Size __n, _Generator __gen)
    {





      for ( ; __n > 0; --__n, ++__first)
        *__first = __gen();
      return __first;
    }
# 969 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename _Tp>
    _OutputIter
    remove_copy(_InputIter __first, _InputIter __last,
                _OutputIter __result, const _Tp& __value)
    {







      for ( ; __first != __last; ++__first)
        if (!(*__first == __value)) {
          *__result = *__first;
          ++__result;
        }
      return __result;
    }
# 1003 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_Predicate>
    _OutputIter
    remove_copy_if(_InputIter __first, _InputIter __last,
                   _OutputIter __result, _Predicate __pred)
    {







      for ( ; __first != __last; ++__first)
        if (!__pred(*__first)) {
          *__result = *__first;
          ++__result;
        }
      return __result;
    }
# 1039 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    _ForwardIter
    remove(_ForwardIter __first, _ForwardIter __last,
           const _Tp& __value)
    {







      __first = find(__first, __last, __value);
      _ForwardIter __i = __first;
      return __first == __last ? __first
                               : remove_copy(++__i, __last, __first,
__value);
    }
# 1073 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate>
    _ForwardIter
    remove_if(_ForwardIter __first, _ForwardIter __last,
              _Predicate __pred)
    {





      __first = find_if(__first, __last, __pred);
      _ForwardIter __i = __first;
      return __first == __last ? __first
                               : remove_copy_if(++__i, __last, __first,
__pred);
    }







  template<typename _InputIter, typename _OutputIter>
    _OutputIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _OutputIter __result,
                  output_iterator_tag)
    {

      typename iterator_traits<_InputIter>::value_type __value =
*__first;
      *__result = __value;
      while (++__first != __last)
        if (!(__value == *__first)) {
          __value = *__first;
          *++__result = __value;
        }
      return ++__result;
    }







  template<typename _InputIter, typename _ForwardIter>
    _ForwardIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _ForwardIter __result,
                  forward_iterator_tag)
    {

      *__result = *__first;
      while (++__first != __last)
        if (!(*__result == *__first))
          *++__result = *__first;
      return ++__result;
    }
# 1145 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter>
    inline _OutputIter
    unique_copy(_InputIter __first, _InputIter __last,
                _OutputIter __result)
    {







      typedef typename iterator_traits<_OutputIter>::iterator_category
_IterType;

      if (__first == __last) return __result;
      return __unique_copy(__first, __last, __result, _IterType());
    }
# 1170 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_BinaryPredicate>
    _OutputIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _OutputIter __result,
                  _BinaryPredicate __binary_pred,
                  output_iterator_tag)
    {





      typename iterator_traits<_InputIter>::value_type __value =
*__first;
      *__result = __value;
      while (++__first != __last)
        if (!__binary_pred(__value, *__first)) {
          __value = *__first;
          *++__result = __value;
        }
      return ++__result;
    }
# 1199 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _ForwardIter, typename
_BinaryPredicate>
    _ForwardIter
    __unique_copy(_InputIter __first, _InputIter __last,
                  _ForwardIter __result,
                  _BinaryPredicate __binary_pred,
                  forward_iterator_tag)
    {





      *__result = *__first;
      while (++__first != __last)
        if (!__binary_pred(*__result, *__first)) *++__result = *__first;
      return ++__result;
    }
# 1232 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _OutputIter, typename
_BinaryPredicate>
    inline _OutputIter
    unique_copy(_InputIter __first, _InputIter __last,
                _OutputIter __result,
                _BinaryPredicate __binary_pred)
    {





      typedef typename iterator_traits<_OutputIter>::iterator_category
_IterType;

      if (__first == __last) return __result;
      return __unique_copy(__first, __last,
__result, __binary_pred, _IterType());
    }
# 1263 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter>
    _ForwardIter
    unique(_ForwardIter __first, _ForwardIter __last)
    {





          __first = adjacent_find(__first, __last);
          return unique_copy(__first, __last, __first);
    }
# 1290 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _BinaryPredicate>
    _ForwardIter
    unique(_ForwardIter __first, _ForwardIter __last,
           _BinaryPredicate __binary_pred)
    {






      __first = adjacent_find(__first, __last, __binary_pred);
      return unique_copy(__first, __last, __first, __binary_pred);
    }







  template<typename _BidirectionalIter>
    void
    __reverse(_BidirectionalIter __first, _BidirectionalIter __last,
                          bidirectional_iterator_tag)
    {
          while (true)
            if (__first == __last || __first == --__last)
                  return;
            else
                  iter_swap(__first++, __last);
    }







  template<typename _RandomAccessIter>
    void
    __reverse(_RandomAccessIter __first, _RandomAccessIter __last,
                          random_access_iterator_tag)
    {
          while (__first < __last)
            iter_swap(__first++, --__last);
    }
# 1349 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter>
    inline void
    reverse(_BidirectionalIter __first, _BidirectionalIter __last)
    {



          __reverse(__first, __last, __iterator_category(__first));
    }
# 1374 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter, typename _OutputIter>
    _OutputIter
    reverse_copy(_BidirectionalIter __first, _BidirectionalIter __last,
                             _OutputIter __result)
    {





      while (__first != __last) {
        --__last;
        *__result = *__last;
        ++__result;
      }
      return __result;
    }
# 1399 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _EuclideanRingElement>
    _EuclideanRingElement
    __gcd(_EuclideanRingElement __m, _EuclideanRingElement __n)
    {
      while (__n != 0) {
        _EuclideanRingElement __t = __m % __n;
        __m = __n;
        __n = __t;
      }
      return __m;
    }






  template<typename _ForwardIter>
    void
    __rotate(_ForwardIter __first,
             _ForwardIter __middle,
             _ForwardIter __last,
              forward_iterator_tag)
    {
      if ((__first == __middle) || (__last == __middle))
        return;

      _ForwardIter __first2 = __middle;
      do {
        swap(*__first++, *__first2++);
        if (__first == __middle)
          __middle = __first2;
      } while (__first2 != __last);

      __first2 = __middle;

      while (__first2 != __last) {
        swap(*__first++, *__first2++);
        if (__first == __middle)
          __middle = __first2;
        else if (__first2 == __last)
          __first2 = __middle;
      }
    }






  template<typename _BidirectionalIter>
    void
    __rotate(_BidirectionalIter __first,
             _BidirectionalIter __middle,
             _BidirectionalIter __last,
              bidirectional_iterator_tag)
    {




      if ((__first == __middle) || (__last == __middle))
        return;

      __reverse(__first, __middle, bidirectional_iterator_tag());
      __reverse(__middle, __last, bidirectional_iterator_tag());

      while (__first != __middle && __middle != __last)
        swap (*__first++, *--__last);

      if (__first == __middle) {
        __reverse(__middle, __last, bidirectional_iterator_tag());
      }
      else {
        __reverse(__first, __middle, bidirectional_iterator_tag());
      }
    }






  template<typename _RandomAccessIter>
    void
    __rotate(_RandomAccessIter __first,
             _RandomAccessIter __middle,
             _RandomAccessIter __last,
             random_access_iterator_tag)
    {




      if ((__first == __middle) || (__last == __middle))
        return;

      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _Distance;
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      _Distance __n = __last - __first;
      _Distance __k = __middle - __first;
      _Distance __l = __n - __k;

      if (__k == __l) {
        swap_ranges(__first, __middle, __middle);
        return;
      }

      _Distance __d = __gcd(__n, __k);

      for (_Distance __i = 0; __i < __d; __i++) {
        _ValueType __tmp = *__first;
        _RandomAccessIter __p = __first;

        if (__k < __l) {
          for (_Distance __j = 0; __j < __l/__d; __j++) {
            if (__p > __first + __l) {
              *__p = *(__p - __l);
              __p -= __l;
            }

            *__p = *(__p + __k);
            __p += __k;
          }
        }

        else {
          for (_Distance __j = 0; __j < __k/__d - 1; __j ++) {
            if (__p < __last - __k) {
              *__p = *(__p + __k);
              __p += __k;
            }

            *__p = * (__p - __l);
            __p -= __l;
          }
        }

        *__p = __tmp;
        ++__first;
      }
    }
# 1561 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter>
    inline void
    rotate(_ForwardIter __first, _ForwardIter __middle, _ForwardIter
__last)
    {



      typedef typename iterator_traits<_ForwardIter>::iterator_category
_IterType;
      __rotate(__first, __middle, __last, _IterType());
    }
# 1589 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _OutputIter>
    _OutputIter
    rotate_copy(_ForwardIter __first, _ForwardIter __middle,
                _ForwardIter __last, _OutputIter __result)
    {





      return copy(__first, __middle, copy(__middle, __last, __result));
    }
# 1612 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _Distance>
    inline _Distance
    __random_number(_Distance __n)
    {

      return lrand48() % __n;



    }
# 1634 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    inline void
    random_shuffle(_RandomAccessIter __first, _RandomAccessIter __last)
    {




      if (__first == __last) return;
      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
        iter_swap(__i, __first + __random_number((__i - __first) + 1));
    }
# 1660 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _RandomNumberGenerator>
    void
    random_shuffle(_RandomAccessIter __first, _RandomAccessIter __last,
                   _RandomNumberGenerator& __rand)
    {




      if (__first == __last) return;
      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
        iter_swap(__i, __first + __rand((__i - __first) + 1));
    }







  template<typename _ForwardIter, typename _Predicate>
    _ForwardIter
    __partition(_ForwardIter __first, _ForwardIter __last,
                _Predicate __pred,
                forward_iterator_tag)
    {
      if (__first == __last) return __first;

      while (__pred(*__first))
        if (++__first == __last) return __first;

      _ForwardIter __next = __first;

      while (++__next != __last)
        if (__pred(*__next)) {
          swap(*__first, *__next);
          ++__first;
        }

      return __first;
    }






  template<typename _BidirectionalIter, typename _Predicate>
    _BidirectionalIter
    __partition(_BidirectionalIter __first, _BidirectionalIter __last,
                _Predicate __pred,
                bidirectional_iterator_tag)
    {
      while (true) {
        while (true)
          if (__first == __last)
            return __first;
          else if (__pred(*__first))
            ++__first;
          else
            break;
        --__last;
        while (true)
          if (__first == __last)
            return __first;
          else if (!__pred(*__last))
            --__last;
          else
            break;
        iter_swap(__first, __last);
        ++__first;
      }
    }
# 1748 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate>
    inline _ForwardIter
    partition(_ForwardIter __first, _ForwardIter __last,
              _Predicate __pred)
    {





      return __partition(__first, __last, __pred,
__iterator_category(__first));
    }







  template<typename _ForwardIter, typename _Predicate, typename
_Distance>
    _ForwardIter
    __inplace_stable_partition(_ForwardIter __first, _ForwardIter
__last,
                               _Predicate __pred, _Distance __len)
    {
      if (__len == 1)
        return __pred(*__first) ? __last : __first;
      _ForwardIter __middle = __first;
      advance(__middle, __len / 2);
      _ForwardIter __begin = __inplace_stable_partition(__first,
__middle,
                                                        __pred,
                                                        __len / 2);
      _ForwardIter __end = __inplace_stable_partition(__middle, __last,
                                                      __pred,
                                                      __len - __len /
2);
      rotate(__begin, __middle, __end);
      advance(__begin, distance(__middle, __end));
      return __begin;
    }






  template<typename _ForwardIter, typename _Pointer, typename
_Predicate,
           typename _Distance>
    _ForwardIter
    __stable_partition_adaptive(_ForwardIter __first, _ForwardIter
__last,
                                _Predicate __pred, _Distance __len,
                                _Pointer __buffer,
                                _Distance __buffer_size)
    {
      if (__len <= __buffer_size) {
        _ForwardIter __result1 = __first;
        _Pointer __result2 = __buffer;
        for ( ; __first != __last ; ++__first)
          if (__pred(*__first)) {
            *__result1 = *__first;
            ++__result1;
          }
          else {
            *__result2 = *__first;
            ++__result2;
          }
        copy(__buffer, __result2, __result1);
        return __result1;
      }
      else {
        _ForwardIter __middle = __first;
        advance(__middle, __len / 2);
        _ForwardIter __begin = __stable_partition_adaptive(__first,
__middle,
                                                           __pred,
                                                           __len / 2,
                                                           __buffer,
__buffer_size);
        _ForwardIter __end = __stable_partition_adaptive( __middle,
__last,
                                                          __pred,
                                                          __len - __len
/ 2,
                                                          __buffer,
__buffer_size);
        rotate(__begin, __middle, __end);
        advance(__begin, distance(__middle, __end));
        return __begin;
      }
    }
# 1848 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Predicate>
    _ForwardIter
    stable_partition(_ForwardIter __first, _ForwardIter __last,
                     _Predicate __pred)
    {





      if (__first == __last)
        return __first;
      else
      {
        typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
        typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;

        _Temporary_buffer<_ForwardIter, _ValueType> __buf(__first,
__last);
        if (__buf.size() > 0)
          return __stable_partition_adaptive(__first, __last, __pred,

_DistanceType(__buf.requested_size()),
                                             __buf.begin(),
__buf.size());
        else
          return __inplace_stable_partition(__first, __last, __pred,

_DistanceType(__buf.requested_size()));
      }
    }






  template<typename _RandomAccessIter, typename _Tp>
    _RandomAccessIter
    __unguarded_partition(_RandomAccessIter __first, _RandomAccessIter
__last,
                          _Tp __pivot)
    {
      while (true) {
        while (*__first < __pivot)
          ++__first;
        --__last;
        while (__pivot < *__last)
          --__last;
        if (!(__first < __last))
          return __first;
        iter_swap(__first, __last);
        ++__first;
      }
    }






  template<typename _RandomAccessIter, typename _Tp, typename _Compare>
    _RandomAccessIter
    __unguarded_partition(_RandomAccessIter __first, _RandomAccessIter
__last,
                          _Tp __pivot, _Compare __comp)
    {
      while (true) {
        while (__comp(*__first, __pivot))
          ++__first;
        --__last;
        while (__comp(__pivot, *__last))
          --__last;
        if (!(__first < __last))
          return __first;
        iter_swap(__first, __last);
        ++__first;
      }
    }
# 1929 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  enum { _M_threshold = 16 };






  template<typename _RandomAccessIter, typename _Tp>
    void
    __unguarded_linear_insert(_RandomAccessIter __last, _Tp __val)
    {
      _RandomAccessIter __next = __last;
      --__next;
      while (__val < *__next) {
        *__last = *__next;
        __last = __next;
        --__next;
      }
      *__last = __val;
    }






  template<typename _RandomAccessIter, typename _Tp, typename _Compare>
    void
    __unguarded_linear_insert(_RandomAccessIter __last, _Tp __val,
_Compare __comp)
    {
      _RandomAccessIter __next = __last;
      --__next;
      while (__comp(__val, *__next)) {
        *__last = *__next;
        __last = __next;
        --__next;
      }
      *__last = __val;
    }






  template<typename _RandomAccessIter>
    void
    __insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last)
    {
      if (__first == __last) return;

      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
      {
        typename iterator_traits<_RandomAccessIter>::value_type __val =
*__i;
        if (__val < *__first) {
          copy_backward(__first, __i, __i + 1);
          *__first = __val;
        }
        else
          __unguarded_linear_insert(__i, __val);
      }
    }






  template<typename _RandomAccessIter, typename _Compare>
    void
    __insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                     _Compare __comp)
    {
      if (__first == __last) return;

      for (_RandomAccessIter __i = __first + 1; __i != __last; ++__i)
      {
        typename iterator_traits<_RandomAccessIter>::value_type __val =
*__i;
        if (__comp(__val, *__first)) {
          copy_backward(__first, __i, __i + 1);
          *__first = __val;
        }
        else
          __unguarded_linear_insert(__i, __val, __comp);
      }
    }






  template<typename _RandomAccessIter>
    inline void
    __unguarded_insertion_sort(_RandomAccessIter __first,
_RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      for (_RandomAccessIter __i = __first; __i != __last; ++__i)
        __unguarded_linear_insert(__i, _ValueType(*__i));
    }






  template<typename _RandomAccessIter, typename _Compare>
    inline void
    __unguarded_insertion_sort(_RandomAccessIter __first,
_RandomAccessIter __last,
                               _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      for (_RandomAccessIter __i = __first; __i != __last; ++__i)
        __unguarded_linear_insert(__i, _ValueType(*__i), __comp);
    }






  template<typename _RandomAccessIter>
    void
    __final_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last)
    {
      if (__last - __first > _M_threshold) {
        __insertion_sort(__first, __first + _M_threshold);
        __unguarded_insertion_sort(__first + _M_threshold, __last);
      }
      else
        __insertion_sort(__first, __last);
    }






  template<typename _RandomAccessIter, typename _Compare>
    void
    __final_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Compare __comp)
    {
      if (__last - __first > _M_threshold) {
        __insertion_sort(__first, __first + _M_threshold, __comp);
        __unguarded_insertion_sort(__first + _M_threshold, __last,
__comp);
      }
      else
        __insertion_sort(__first, __last, __comp);
    }






  template<typename _Size>
    inline _Size
    __lg(_Size __n)
    {
      _Size __k;
      for (__k = 0; __n != 1; __n >>= 1) ++__k;
      return __k;
    }






  template<typename _RandomAccessIter, typename _Size>
    void
    __introsort_loop(_RandomAccessIter __first, _RandomAccessIter
__last,
                     _Size __depth_limit)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      while (__last - __first > _M_threshold) {
        if (__depth_limit == 0) {
          partial_sort(__first, __last, __last);
          return;
        }
        --__depth_limit;
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1))));
        __introsort_loop(__cut, __last, __depth_limit);
        __last = __cut;
      }
    }






  template<typename _RandomAccessIter, typename _Size, typename
_Compare>
    void
    __introsort_loop(_RandomAccessIter __first, _RandomAccessIter
__last,
                     _Size __depth_limit, _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;

      while (__last - __first > _M_threshold) {
        if (__depth_limit == 0) {
          partial_sort(__first, __last, __last, __comp);
          return;
        }
        --__depth_limit;
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1),
__comp)),
           __comp);
        __introsort_loop(__cut, __last, __depth_limit, __comp);
        __last = __cut;
      }
    }
# 2166 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    inline void
    sort(_RandomAccessIter __first, _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      if (__first != __last) {
        __introsort_loop(__first, __last, __lg(__last - __first) * 2);
        __final_insertion_sort(__first, __last);
      }
    }
# 2197 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    inline void
    sort(_RandomAccessIter __first, _RandomAccessIter __last, _Compare
__comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      if (__first != __last) {
        __introsort_loop(__first, __last, __lg(__last - __first) * 2,
__comp);
        __final_insertion_sort(__first, __last, __comp);
      }
    }







  template<typename _RandomAccessIter>
    void
    __inplace_stable_sort(_RandomAccessIter __first, _RandomAccessIter
__last)
    {
      if (__last - __first < 15) {
        __insertion_sort(__first, __last);
        return;
      }
      _RandomAccessIter __middle = __first + (__last - __first) / 2;
      __inplace_stable_sort(__first, __middle);
      __inplace_stable_sort(__middle, __last);
      __merge_without_buffer(__first, __middle, __last,
                             __middle - __first,
                             __last - __middle);
    }






  template<typename _RandomAccessIter, typename _Compare>
    void
    __inplace_stable_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                          _Compare __comp)
    {
      if (__last - __first < 15) {
        __insertion_sort(__first, __last, __comp);
        return;
      }
      _RandomAccessIter __middle = __first + (__last - __first) / 2;
      __inplace_stable_sort(__first, __middle, __comp);
      __inplace_stable_sort(__middle, __last, __comp);
      __merge_without_buffer(__first, __middle, __last,
                             __middle - __first,
                             __last - __middle,
                             __comp);
    }

  template<typename _RandomAccessIter1, typename _RandomAccessIter2,
           typename _Distance>
    void
    __merge_sort_loop(_RandomAccessIter1 __first, _RandomAccessIter1
__last,
                      _RandomAccessIter2 __result, _Distance
__step_size)
    {
      _Distance __two_step = 2 * __step_size;

      while (__last - __first >= __two_step) {
        __result = merge(__first, __first + __step_size,
                         __first + __step_size, __first + __two_step,
                         __result);
        __first += __two_step;
      }

      __step_size = min(_Distance(__last - __first), __step_size);
      merge(__first, __first + __step_size, __first + __step_size,
__last,
            __result);
    }

  template<typename _RandomAccessIter1, typename _RandomAccessIter2,
           typename _Distance, typename _Compare>
    void
    __merge_sort_loop(_RandomAccessIter1 __first, _RandomAccessIter1
__last,
                      _RandomAccessIter2 __result, _Distance
__step_size,
                      _Compare __comp)
    {
      _Distance __two_step = 2 * __step_size;

      while (__last - __first >= __two_step) {
        __result = merge(__first, __first + __step_size,
                         __first + __step_size, __first + __two_step,
                         __result,
                         __comp);
        __first += __two_step;
      }
      __step_size = min(_Distance(__last - __first), __step_size);

      merge(__first, __first + __step_size,
            __first + __step_size, __last,
            __result,
            __comp);
    }

  enum { _M_chunk_size = 7 };

  template<typename _RandomAccessIter, typename _Distance>
    void
    __chunk_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Distance __chunk_size)
    {
      while (__last - __first >= __chunk_size) {
        __insertion_sort(__first, __first + __chunk_size);
        __first += __chunk_size;
      }
      __insertion_sort(__first, __last);
    }

  template<typename _RandomAccessIter, typename _Distance, typename
_Compare>
    void
    __chunk_insertion_sort(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Distance __chunk_size, _Compare __comp)
    {
      while (__last - __first >= __chunk_size) {
        __insertion_sort(__first, __first + __chunk_size, __comp);
        __first += __chunk_size;
      }
      __insertion_sort(__first, __last, __comp);
    }

  template<typename _RandomAccessIter, typename _Pointer>
    void
    __merge_sort_with_buffer(_RandomAccessIter __first,
_RandomAccessIter __last,
                             _Pointer __buffer)
    {
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _Distance;

      _Distance __len = __last - __first;
      _Pointer __buffer_last = __buffer + __len;

      _Distance __step_size = _M_chunk_size;
      __chunk_insertion_sort(__first, __last, __step_size);

      while (__step_size < __len) {
        __merge_sort_loop(__first, __last, __buffer, __step_size);
        __step_size *= 2;
        __merge_sort_loop(__buffer, __buffer_last, __first,
__step_size);
        __step_size *= 2;
      }
    }

  template<typename _RandomAccessIter, typename _Pointer, typename
_Compare>
    void
    __merge_sort_with_buffer(_RandomAccessIter __first,
_RandomAccessIter __last,
                             _Pointer __buffer, _Compare __comp)
    {
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _Distance;

      _Distance __len = __last - __first;
      _Pointer __buffer_last = __buffer + __len;

      _Distance __step_size = _M_chunk_size;
      __chunk_insertion_sort(__first, __last, __step_size, __comp);

      while (__step_size < __len) {
        __merge_sort_loop(__first, __last, __buffer, __step_size,
__comp);
        __step_size *= 2;
        __merge_sort_loop(__buffer, __buffer_last, __first, __step_size,
__comp);
        __step_size *= 2;
      }
    }

  template<typename _RandomAccessIter, typename _Pointer, typename
_Distance>
    void
    __stable_sort_adaptive(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Pointer __buffer, _Distance __buffer_size)
    {
      _Distance __len = (__last - __first + 1) / 2;
      _RandomAccessIter __middle = __first + __len;
      if (__len > __buffer_size) {
        __stable_sort_adaptive(__first, __middle, __buffer,
__buffer_size);
        __stable_sort_adaptive(__middle, __last, __buffer,
__buffer_size);
      }
      else {
        __merge_sort_with_buffer(__first, __middle, __buffer);
        __merge_sort_with_buffer(__middle, __last, __buffer);
      }
      __merge_adaptive(__first, __middle, __last, _Distance(__middle -
__first),
                       _Distance(__last - __middle), __buffer,
__buffer_size);
    }

  template<typename _RandomAccessIter, typename _Pointer, typename
_Distance,
           typename _Compare>
    void
    __stable_sort_adaptive(_RandomAccessIter __first, _RandomAccessIter
__last,
                           _Pointer __buffer, _Distance __buffer_size,
                           _Compare __comp)
    {
      _Distance __len = (__last - __first + 1) / 2;
      _RandomAccessIter __middle = __first + __len;
      if (__len > __buffer_size) {
        __stable_sort_adaptive(__first, __middle, __buffer,
__buffer_size,
                               __comp);
        __stable_sort_adaptive(__middle, __last, __buffer,
__buffer_size,
                               __comp);
      }
      else {
        __merge_sort_with_buffer(__first, __middle, __buffer, __comp);
        __merge_sort_with_buffer(__middle, __last, __buffer, __comp);
      }
      __merge_adaptive(__first, __middle, __last, _Distance(__middle -
__first),
                       _Distance(__last - __middle), __buffer,
__buffer_size,
                       __comp);
    }
# 2430 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    inline void
    stable_sort(_RandomAccessIter __first, _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;






      _Temporary_buffer<_RandomAccessIter, _ValueType> buf(__first,
__last);
      if (buf.begin() == 0)
        __inplace_stable_sort(__first, __last);
      else
        __stable_sort_adaptive(__first, __last, buf.begin(),
_DistanceType(buf.size()));
    }
# 2466 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    inline void
    stable_sort(_RandomAccessIter __first, _RandomAccessIter __last,
_Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;







      _Temporary_buffer<_RandomAccessIter, _ValueType> buf(__first,
__last);
      if (buf.begin() == 0)
        __inplace_stable_sort(__first, __last, __comp);
      else
        __stable_sort_adaptive(__first, __last, buf.begin(),
_DistanceType(buf.size()),
                               __comp);
    }
# 2502 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    void
    partial_sort(_RandomAccessIter __first,
                 _RandomAccessIter __middle,
                 _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      make_heap(__first, __middle);
      for (_RandomAccessIter __i = __middle; __i < __last; ++__i)
        if (*__i < *__first)
          __pop_heap(__first, __middle, __i, _ValueType(*__i));
      sort_heap(__first, __middle);
    }
# 2540 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    void
    partial_sort(_RandomAccessIter __first,
                 _RandomAccessIter __middle,
                 _RandomAccessIter __last,
                 _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;







      make_heap(__first, __middle, __comp);
      for (_RandomAccessIter __i = __middle; __i < __last; ++__i)
        if (__comp(*__i, *__first))
          __pop_heap(__first, __middle, __i, _ValueType(*__i), __comp);
      sort_heap(__first, __middle, __comp);
    }
# 2579 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _RandomAccessIter>
    _RandomAccessIter
    partial_sort_copy(_InputIter __first, _InputIter __last,
                      _RandomAccessIter __result_first,
                      _RandomAccessIter __result_last)
    {
      typedef typename iterator_traits<_InputIter>::value_type
_InputValueType;
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_OutputValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;







      if (__result_first == __result_last) return __result_last;
      _RandomAccessIter __result_real_last = __result_first;
      while(__first != __last && __result_real_last != __result_last) {
        *__result_real_last = *__first;
        ++__result_real_last;
        ++__first;
      }
      make_heap(__result_first, __result_real_last);
      while (__first != __last) {
        if (*__first < *__result_first)
          __adjust_heap(__result_first, _DistanceType(0),
                        _DistanceType(__result_real_last -
__result_first),
                        _InputValueType(*__first));
        ++__first;
      }
      sort_heap(__result_first, __result_real_last);
      return __result_real_last;
    }
# 2633 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter, typename _RandomAccessIter, typename
_Compare>
    _RandomAccessIter
    partial_sort_copy(_InputIter __first, _InputIter __last,
                      _RandomAccessIter __result_first,
                      _RandomAccessIter __result_last,
                      _Compare __comp)
    {
      typedef typename iterator_traits<_InputIter>::value_type
_InputValueType;
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_OutputValueType;
      typedef typename
iterator_traits<_RandomAccessIter>::difference_type _DistanceType;








      if (__result_first == __result_last) return __result_last;
      _RandomAccessIter __result_real_last = __result_first;
      while(__first != __last && __result_real_last != __result_last) {
        *__result_real_last = *__first;
        ++__result_real_last;
        ++__first;
      }
      make_heap(__result_first, __result_real_last, __comp);
      while (__first != __last) {
        if (__comp(*__first, *__result_first))
          __adjust_heap(__result_first, _DistanceType(0),
                        _DistanceType(__result_real_last -
__result_first),
                        _InputValueType(*__first),
                        __comp);
        ++__first;
      }
      sort_heap(__result_first, __result_real_last, __comp);
      return __result_real_last;
    }
# 2686 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter>
    void
    nth_element(_RandomAccessIter __first,
                _RandomAccessIter __nth,
                _RandomAccessIter __last)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;





      while (__last - __first > 3) {
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1))));
        if (__cut <= __nth)
          __first = __cut;
        else
          __last = __cut;
      }
      __insertion_sort(__first, __last);
    }
# 2728 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _RandomAccessIter, typename _Compare>
    void
    nth_element(_RandomAccessIter __first,
                _RandomAccessIter __nth,
                _RandomAccessIter __last,
                            _Compare __comp)
    {
      typedef typename iterator_traits<_RandomAccessIter>::value_type
_ValueType;






      while (__last - __first > 3) {
        _RandomAccessIter __cut =
          __unguarded_partition(__first, __last,
                                _ValueType(__median(*__first,
                                                    *(__first + (__last
- __first)/2),
                                                    *(__last - 1),
                                                    __comp)),
                                __comp);
        if (__cut <= __nth)
          __first = __cut;
        else
          __last = __cut;
      }
      __insertion_sort(__first, __last, __comp);
    }
# 2768 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    _ForwardIter
    lower_bound(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;










      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (*__middle < __val) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else
          __len = __half;
      }
      return __first;
    }
# 2816 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    _ForwardIter
    lower_bound(_ForwardIter __first, _ForwardIter __last,
                const _Tp& __val, _Compare __comp)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;





      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__comp(*__middle, __val)) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else
          __len = __half;
      }
      return __first;
    }
# 2856 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    _ForwardIter
    upper_bound(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;







      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__val < *__middle)
          __len = __half;
        else {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
      }
      return __first;
    }
# 2901 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    _ForwardIter
    upper_bound(_ForwardIter __first, _ForwardIter __last,
                const _Tp& __val, _Compare __comp)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;





      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__comp(__val, *__middle))
          __len = __half;
        else {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
      }
      return __first;
    }
# 2948 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    pair<_ForwardIter, _ForwardIter>
    equal_range(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;







      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle, __left, __right;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (*__middle < __val) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else if (__val < *__middle)
          __len = __half;
        else {
          __left = lower_bound(__first, __middle, __val);
          advance(__first, __len);
          __right = upper_bound(++__middle, __first, __val);
          return pair<_ForwardIter, _ForwardIter>(__left, __right);
        }
      }
      return pair<_ForwardIter, _ForwardIter>(__first, __first);
    }
# 3003 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    pair<_ForwardIter, _ForwardIter>
    equal_range(_ForwardIter __first, _ForwardIter __last, const _Tp&
__val,
                _Compare __comp)
    {
      typedef typename iterator_traits<_ForwardIter>::value_type
_ValueType;
      typedef typename iterator_traits<_ForwardIter>::difference_type
_DistanceType;






      _DistanceType __len = distance(__first, __last);
      _DistanceType __half;
      _ForwardIter __middle, __left, __right;

      while (__len > 0) {
        __half = __len >> 1;
        __middle = __first;
        advance(__middle, __half);
        if (__comp(*__middle, __val)) {
          __first = __middle;
          ++__first;
          __len = __len - __half - 1;
        }
        else if (__comp(__val, *__middle))
          __len = __half;
        else {
          __left = lower_bound(__first, __middle, __val, __comp);
          advance(__first, __len);
          __right = upper_bound(++__middle, __first, __val, __comp);
          return pair<_ForwardIter, _ForwardIter>(__left, __right);
        }
      }
      return pair<_ForwardIter, _ForwardIter>(__first, __first);
    }
# 3052 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp>
    bool
    binary_search(_ForwardIter __first, _ForwardIter __last,
                  const _Tp& __val)
    {







      _ForwardIter __i = lower_bound(__first, __last, __val);
      return __i != __last && !(__val < *__i);
    }
# 3083 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter, typename _Tp, typename _Compare>
    bool
    binary_search(_ForwardIter __first, _ForwardIter __last,
                  const _Tp& __val, _Compare __comp)
    {







      _ForwardIter __i = lower_bound(__first, __last, __val, __comp);
      return __i != __last && !__comp(__val, *__i);
    }
# 3115 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    merge(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2, _InputIter2 __last2,
          _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2) {
        if (*__first2 < *__first1) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }
# 3166 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    merge(_InputIter1 __first1, _InputIter1 __last1,
          _InputIter2 __first2, _InputIter2 __last2,
          _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2) {
        if (__comp(*__first2, *__first1)) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }






  template<typename _BidirectionalIter, typename _Distance>
    void
    __merge_without_buffer(_BidirectionalIter __first,
                           _BidirectionalIter __middle,
                           _BidirectionalIter __last,
                           _Distance __len1, _Distance __len2)
    {
      if (__len1 == 0 || __len2 == 0)
        return;
      if (__len1 + __len2 == 2) {
        if (*__middle < *__first)
              iter_swap(__first, __middle);
        return;
      }
      _BidirectionalIter __first_cut = __first;
      _BidirectionalIter __second_cut = __middle;
      _Distance __len11 = 0;
      _Distance __len22 = 0;
      if (__len1 > __len2) {
        __len11 = __len1 / 2;
        advance(__first_cut, __len11);
        __second_cut = lower_bound(__middle, __last, *__first_cut);
        __len22 = distance(__middle, __second_cut);
      }
      else {
        __len22 = __len2 / 2;
        advance(__second_cut, __len22);
        __first_cut = upper_bound(__first, __middle, *__second_cut);
        __len11 = distance(__first, __first_cut);
      }
      rotate(__first_cut, __middle, __second_cut);
      _BidirectionalIter __new_middle = __first_cut;
      advance(__new_middle, distance(__middle, __second_cut));
      __merge_without_buffer(__first, __first_cut, __new_middle,
                             __len11, __len22);
      __merge_without_buffer(__new_middle, __second_cut, __last,
                             __len1 - __len11, __len2 - __len22);
    }






  template<typename _BidirectionalIter, typename _Distance, typename
_Compare>
    void
    __merge_without_buffer(_BidirectionalIter __first,
                           _BidirectionalIter __middle,
                           _BidirectionalIter __last,
                           _Distance __len1, _Distance __len2,
                           _Compare __comp)
    {
      if (__len1 == 0 || __len2 == 0)
        return;
      if (__len1 + __len2 == 2) {
        if (__comp(*__middle, *__first))
              iter_swap(__first, __middle);
        return;
      }
      _BidirectionalIter __first_cut = __first;
      _BidirectionalIter __second_cut = __middle;
      _Distance __len11 = 0;
      _Distance __len22 = 0;
      if (__len1 > __len2) {
        __len11 = __len1 / 2;
        advance(__first_cut, __len11);
        __second_cut = lower_bound(__middle, __last, *__first_cut,
__comp);
        __len22 = distance(__middle, __second_cut);
      }
      else {
        __len22 = __len2 / 2;
        advance(__second_cut, __len22);
        __first_cut = upper_bound(__first, __middle, *__second_cut,
__comp);
        __len11 = distance(__first, __first_cut);
      }
      rotate(__first_cut, __middle, __second_cut);
      _BidirectionalIter __new_middle = __first_cut;
      advance(__new_middle, distance(__middle, __second_cut));
      __merge_without_buffer(__first, __first_cut, __new_middle,
                             __len11, __len22, __comp);
      __merge_without_buffer(__new_middle, __second_cut, __last,
                             __len1 - __len11, __len2 - __len22,
__comp);
    }






  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _Distance>
    _BidirectionalIter1
    __rotate_adaptive(_BidirectionalIter1 __first,
                      _BidirectionalIter1 __middle,
                      _BidirectionalIter1 __last,
                      _Distance __len1, _Distance __len2,
                      _BidirectionalIter2 __buffer,
                      _Distance __buffer_size)
    {
      _BidirectionalIter2 __buffer_end;
      if (__len1 > __len2 && __len2 <= __buffer_size) {
        __buffer_end = copy(__middle, __last, __buffer);
        copy_backward(__first, __middle, __last);
        return copy(__buffer, __buffer_end, __first);
      }
      else if (__len1 <= __buffer_size) {
        __buffer_end = copy(__first, __middle, __buffer);
        copy(__middle, __last, __first);
        return copy_backward(__buffer, __buffer_end, __last);
      }
      else {
        rotate(__first, __middle, __last);
        advance(__first, distance(__middle, __last));
        return __first;
      }
    }






  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BidirectionalIter3>
    _BidirectionalIter3
    __merge_backward(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
                     _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
                     _BidirectionalIter3 __result)
    {
      if (__first1 == __last1)
        return copy_backward(__first2, __last2, __result);
      if (__first2 == __last2)
        return copy_backward(__first1, __last1, __result);
      --__last1;
      --__last2;
      while (true) {
        if (*__last2 < *__last1) {
          *--__result = *__last1;
          if (__first1 == __last1)
            return copy_backward(__first2, ++__last2, __result);
          --__last1;
        }
        else {
          *--__result = *__last2;
          if (__first2 == __last2)
            return copy_backward(__first1, ++__last1, __result);
          --__last2;
        }
      }
    }






  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BidirectionalIter3, typename _Compare>
    _BidirectionalIter3
    __merge_backward(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
                     _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
                     _BidirectionalIter3 __result,
                     _Compare __comp)
    {
      if (__first1 == __last1)
        return copy_backward(__first2, __last2, __result);
      if (__first2 == __last2)
        return copy_backward(__first1, __last1, __result);
      --__last1;
      --__last2;
      while (true) {
        if (__comp(*__last2, *__last1)) {
          *--__result = *__last1;
          if (__first1 == __last1)
            return copy_backward(__first2, ++__last2, __result);
          --__last1;
        }
        else {
          *--__result = *__last2;
          if (__first2 == __last2)
            return copy_backward(__first1, ++__last1, __result);
          --__last2;
        }
      }
    }






  template<typename _BidirectionalIter, typename _Distance, typename
_Pointer>
    void
    __merge_adaptive(_BidirectionalIter __first,
                     _BidirectionalIter __middle,
                     _BidirectionalIter __last,
                     _Distance __len1, _Distance __len2,
                     _Pointer __buffer, _Distance __buffer_size)
    {
          if (__len1 <= __len2 && __len1 <= __buffer_size) {
            _Pointer __buffer_end = copy(__first, __middle, __buffer);
            merge(__buffer, __buffer_end, __middle, __last, __first);
          }
          else if (__len2 <= __buffer_size) {
            _Pointer __buffer_end = copy(__middle, __last, __buffer);
            __merge_backward(__first, __middle, __buffer, __buffer_end,
__last);
          }
          else {
            _BidirectionalIter __first_cut = __first;
            _BidirectionalIter __second_cut = __middle;
            _Distance __len11 = 0;
            _Distance __len22 = 0;
            if (__len1 > __len2) {
                  __len11 = __len1 / 2;
                  advance(__first_cut, __len11);
                  __second_cut = lower_bound(__middle, __last,
*__first_cut);
                  __len22 = distance(__middle, __second_cut);
            }
            else {
                  __len22 = __len2 / 2;
                  advance(__second_cut, __len22);
                  __first_cut = upper_bound(__first, __middle,
*__second_cut);
                  __len11 = distance(__first, __first_cut);
            }
            _BidirectionalIter __new_middle =
                  __rotate_adaptive(__first_cut, __middle, __second_cut,
                                    __len1 - __len11, __len22, __buffer,
                                    __buffer_size);
            __merge_adaptive(__first, __first_cut, __new_middle,
__len11,
                             __len22, __buffer, __buffer_size);
            __merge_adaptive(__new_middle, __second_cut, __last, __len1
- __len11,
                             __len2 - __len22, __buffer, __buffer_size);
          }
    }






  template<typename _BidirectionalIter, typename _Distance, typename
_Pointer,
           typename _Compare>
    void
    __merge_adaptive(_BidirectionalIter __first,
                     _BidirectionalIter __middle,
                     _BidirectionalIter __last,
                     _Distance __len1, _Distance __len2,
                     _Pointer __buffer, _Distance __buffer_size,
                     _Compare __comp)
    {
          if (__len1 <= __len2 && __len1 <= __buffer_size) {
            _Pointer __buffer_end = copy(__first, __middle, __buffer);
            merge(__buffer, __buffer_end, __middle, __last, __first,
__comp);
          }
          else if (__len2 <= __buffer_size) {
            _Pointer __buffer_end = copy(__middle, __last, __buffer);
            __merge_backward(__first, __middle, __buffer, __buffer_end,
__last,
                                             __comp);
          }
          else {
            _BidirectionalIter __first_cut = __first;
            _BidirectionalIter __second_cut = __middle;
            _Distance __len11 = 0;
            _Distance __len22 = 0;
            if (__len1 > __len2) {
                  __len11 = __len1 / 2;
                  advance(__first_cut, __len11);
                  __second_cut = lower_bound(__middle, __last,
*__first_cut, __comp);
                  __len22 = distance(__middle, __second_cut);
            }
            else {
                  __len22 = __len2 / 2;
                  advance(__second_cut, __len22);
                  __first_cut = upper_bound(__first, __middle,
*__second_cut, __comp);
                  __len11 = distance(__first, __first_cut);
            }
            _BidirectionalIter __new_middle =
                  __rotate_adaptive(__first_cut, __middle, __second_cut,
                                    __len1 - __len11, __len22, __buffer,
                                    __buffer_size);
            __merge_adaptive(__first, __first_cut, __new_middle,
__len11,
                             __len22, __buffer, __buffer_size, __comp);
            __merge_adaptive(__new_middle, __second_cut, __last, __len1
- __len11,
                             __len2 - __len22, __buffer, __buffer_size,
__comp);
          }
    }
# 3508 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter>
    void
    inplace_merge(_BidirectionalIter __first,
                  _BidirectionalIter __middle,
                  _BidirectionalIter __last)
    {
      typedef typename iterator_traits<_BidirectionalIter>::value_type
          _ValueType;
      typedef typename
iterator_traits<_BidirectionalIter>::difference_type
          _DistanceType;






      if (__first == __middle || __middle == __last)
        return;

      _DistanceType __len1 = distance(__first, __middle);
      _DistanceType __len2 = distance(__middle, __last);

      _Temporary_buffer<_BidirectionalIter, _ValueType> __buf(__first,
__last);
      if (__buf.begin() == 0)
        __merge_without_buffer(__first, __middle, __last, __len1,
__len2);
      else
        __merge_adaptive(__first, __middle, __last, __len1, __len2,
                         __buf.begin(), _DistanceType(__buf.size()));
    }
# 3559 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _BidirectionalIter, typename _Compare>
    void
    inplace_merge(_BidirectionalIter __first,
                  _BidirectionalIter __middle,
                  _BidirectionalIter __last,
                  _Compare __comp)
    {
      typedef typename iterator_traits<_BidirectionalIter>::value_type
          _ValueType;
      typedef typename
iterator_traits<_BidirectionalIter>::difference_type
          _DistanceType;







      if (__first == __middle || __middle == __last)
        return;

      _DistanceType __len1 = distance(__first, __middle);
      _DistanceType __len2 = distance(__middle, __last);

      _Temporary_buffer<_BidirectionalIter, _ValueType> __buf(__first,
__last);
      if (__buf.begin() == 0)
        __merge_without_buffer(__first, __middle, __last, __len1,
__len2, __comp);
      else
        __merge_adaptive(__first, __middle, __last, __len1, __len2,
                         __buf.begin(), _DistanceType(__buf.size()),
                         __comp);
    }






  template<typename _InputIter1, typename _InputIter2>
    bool
    includes(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2, _InputIter2 __last2)
    {









      while (__first1 != __last1 && __first2 != __last2)
        if (*__first2 < *__first1)
          return false;
        else if(*__first1 < *__first2)
          ++__first1;
        else
          ++__first1, ++__first2;

      return __first2 == __last2;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_Compare>
    bool
    includes(_InputIter1 __first1, _InputIter1 __last1,
             _InputIter2 __first2, _InputIter2 __last2, _Compare __comp)
    {










      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first2, *__first1))
          return false;
        else if(__comp(*__first1, *__first2))
          ++__first1;
        else
          ++__first1, ++__first2;

      return __first2 == __last2;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_union(_InputIter1 __first1, _InputIter1 __last1,
              _InputIter2 __first2, _InputIter2 __last2,
              _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2) {
        if (*__first1 < *__first2) {
          *__result = *__first1;
          ++__first1;
        }
        else if (*__first2 < *__first1) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_union(_InputIter1 __first1, _InputIter1 __last1,
              _InputIter2 __first2, _InputIter2 __last2,
              _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2) {
        if (__comp(*__first1, *__first2)) {
          *__result = *__first1;
          ++__first1;
        }
        else if (__comp(*__first2, *__first1)) {
          *__result = *__first2;
          ++__first2;
        }
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
        }
        ++__result;
      }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_intersection(_InputIter1 __first1, _InputIter1 __last1,
                     _InputIter2 __first2, _InputIter2 __last2,
                     _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2)
        if (*__first1 < *__first2)
          ++__first1;
        else if (*__first2 < *__first1)
          ++__first2;
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
          ++__result;
        }
      return __result;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_intersection(_InputIter1 __first1, _InputIter1 __last1,
                     _InputIter2 __first2, _InputIter2 __last2,
                     _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first1, *__first2))
          ++__first1;
        else if (__comp(*__first2, *__first1))
          ++__first2;
        else {
          *__result = *__first1;
          ++__first1;
          ++__first2;
          ++__result;
        }
      return __result;
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_difference(_InputIter1 __first1, _InputIter1 __last1,
                   _InputIter2 __first2, _InputIter2 __last2,
                   _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2)
        if (*__first1 < *__first2) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (*__first2 < *__first1)
          ++__first2;
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first1, __last1, __result);
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_difference(_InputIter1 __first1, _InputIter1 __last1,
                   _InputIter2 __first2, _InputIter2 __last2,
                   _OutputIter __result, _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first1, *__first2)) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (__comp(*__first2, *__first1))
          ++__first2;
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first1, __last1, __result);
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter>
    _OutputIter
    set_symmetric_difference(_InputIter1 __first1, _InputIter1 __last1,
                             _InputIter2 __first2, _InputIter2 __last2,
                             _OutputIter __result)
    {











      while (__first1 != __last1 && __first2 != __last2)
        if (*__first1 < *__first2) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (*__first2 < *__first1) {
          *__result = *__first2;
          ++__first2;
          ++__result;
        }
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }

  template<typename _InputIter1, typename _InputIter2, typename
_OutputIter,
           typename _Compare>
    _OutputIter
    set_symmetric_difference(_InputIter1 __first1, _InputIter1 __last1,
                             _InputIter2 __first2, _InputIter2 __last2,
                             _OutputIter __result,
                             _Compare __comp)
    {












      while (__first1 != __last1 && __first2 != __last2)
        if (__comp(*__first1, *__first2)) {
          *__result = *__first1;
          ++__first1;
          ++__result;
        }
        else if (__comp(*__first2, *__first1)) {
          *__result = *__first2;
          ++__first2;
          ++__result;
        }
        else {
          ++__first1;
          ++__first2;
        }
      return copy(__first2, __last2, copy(__first1, __last1, __result));
    }




  template<typename _ForwardIter>
    _ForwardIter
    max_element(_ForwardIter __first, _ForwardIter __last)
    {





      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (*__result < *__first)
          __result = __first;
      return __result;
    }

  template<typename _ForwardIter, typename _Compare>
    _ForwardIter
    max_element(_ForwardIter __first, _ForwardIter __last,
                _Compare __comp)
    {






      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (__comp(*__result, *__first)) __result = __first;
      return __result;
    }

  template<typename _ForwardIter>
    _ForwardIter
    min_element(_ForwardIter __first, _ForwardIter __last)
    {





      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (*__first < *__result)
          __result = __first;
      return __result;
    }

  template<typename _ForwardIter, typename _Compare>
    _ForwardIter
    min_element(_ForwardIter __first, _ForwardIter __last,
                _Compare __comp)
    {






      if (__first == __last) return __first;
      _ForwardIter __result = __first;
      while (++__first != __last)
        if (__comp(*__first, *__result))
          __result = __first;
      return __result;
    }




  template<typename _BidirectionalIter>
    bool
    next_permutation(_BidirectionalIter __first, _BidirectionalIter
__last)
    {





      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (*__i < *__ii) {
          _BidirectionalIter __j = __last;
          while (!(*__i < *--__j))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }

  template<typename _BidirectionalIter, typename _Compare>
    bool
    next_permutation(_BidirectionalIter __first, _BidirectionalIter
__last,
                     _Compare __comp)
    {






      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (__comp(*__i, *__ii)) {
          _BidirectionalIter __j = __last;
          while (!__comp(*__i, *--__j))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }

  template<typename _BidirectionalIter>
    bool
    prev_permutation(_BidirectionalIter __first, _BidirectionalIter
__last)
    {





      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (*__ii < *__i) {
          _BidirectionalIter __j = __last;
          while (!(*--__j < *__i))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }

  template<typename _BidirectionalIter, typename _Compare>
    bool
    prev_permutation(_BidirectionalIter __first, _BidirectionalIter
__last,
                     _Compare __comp)
    {






      if (__first == __last)
        return false;
      _BidirectionalIter __i = __first;
      ++__i;
      if (__i == __last)
        return false;
      __i = __last;
      --__i;

      for(;;) {
        _BidirectionalIter __ii = __i;
        --__i;
        if (__comp(*__ii, *__i)) {
          _BidirectionalIter __j = __last;
          while (!__comp(*--__j, *__i))
            {}
          iter_swap(__i, __j);
          reverse(__ii, __last);
          return true;
        }
        if (__i == __first) {
          reverse(__first, __last);
          return false;
        }
      }
    }



  template<typename _InputIter, typename _ForwardIter>
    _InputIter
    find_first_of(_InputIter __first1, _InputIter __last1,
                  _ForwardIter __first2, _ForwardIter __last2)
    {







      for ( ; __first1 != __last1; ++__first1)
        for (_ForwardIter __iter = __first2; __iter != __last2;
++__iter)
          if (*__first1 == *__iter)
            return __first1;
      return __last1;
    }

  template<typename _InputIter, typename _ForwardIter, typename
_BinaryPredicate>
    _InputIter
    find_first_of(_InputIter __first1, _InputIter __last1,
                  _ForwardIter __first2, _ForwardIter __last2,
                  _BinaryPredicate __comp)
    {










      for ( ; __first1 != __last1; ++__first1)
        for (_ForwardIter __iter = __first2; __iter != __last2;
++__iter)
          if (__comp(*__first1, *__iter))
            return __first1;
      return __last1;
    }
# 4201 "/usr/local/fitools/include/g++-v3/bits/stl_algo.h" 3
  template<typename _ForwardIter1, typename _ForwardIter2>
    _ForwardIter1
    __find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
               _ForwardIter2 __first2, _ForwardIter2 __last2,
               forward_iterator_tag, forward_iterator_tag)
    {
      if (__first2 == __last2)
        return __last1;
      else {
        _ForwardIter1 __result = __last1;
        while (1) {
          _ForwardIter1 __new_result
            = search(__first1, __last1, __first2, __last2);
          if (__new_result == __last1)
            return __result;
          else {
            __result = __new_result;
            __first1 = __new_result;
            ++__first1;
          }
        }
      }
    }

  template<typename _ForwardIter1, typename _ForwardIter2,
           typename _BinaryPredicate>
    _ForwardIter1
    __find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
               _ForwardIter2 __first2, _ForwardIter2 __last2,
               forward_iterator_tag, forward_iterator_tag,
               _BinaryPredicate __comp)
    {
      if (__first2 == __last2)
        return __last1;
      else {
        _ForwardIter1 __result = __last1;
        while (1) {
          _ForwardIter1 __new_result
            = search(__first1, __last1, __first2, __last2, __comp);
          if (__new_result == __last1)
            return __result;
          else {
            __result = __new_result;
            __first1 = __new_result;
            ++__first1;
          }
        }
      }
    }


  template<typename _BidirectionalIter1, typename _BidirectionalIter2>
    _BidirectionalIter1
    __find_end(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
               _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
               bidirectional_iterator_tag, bidirectional_iterator_tag)
    {




      typedef reverse_iterator<_BidirectionalIter1> _RevIter1;
      typedef reverse_iterator<_BidirectionalIter2> _RevIter2;

      _RevIter1 __rlast1(__first1);
      _RevIter2 __rlast2(__first2);
      _RevIter1 __rresult = search(_RevIter1(__last1), __rlast1,
                                   _RevIter2(__last2), __rlast2);

      if (__rresult == __rlast1)
        return __last1;
      else {
        _BidirectionalIter1 __result = __rresult.base();
        advance(__result, -distance(__first2, __last2));
        return __result;
      }
    }

  template<typename _BidirectionalIter1, typename _BidirectionalIter2,
           typename _BinaryPredicate>
    _BidirectionalIter1
    __find_end(_BidirectionalIter1 __first1, _BidirectionalIter1
__last1,
               _BidirectionalIter2 __first2, _BidirectionalIter2
__last2,
               bidirectional_iterator_tag, bidirectional_iterator_tag,
               _BinaryPredicate __comp)
    {




      typedef reverse_iterator<_BidirectionalIter1> _RevIter1;
      typedef reverse_iterator<_BidirectionalIter2> _RevIter2;

      _RevIter1 __rlast1(__first1);
      _RevIter2 __rlast2(__first2);
      _RevIter1 __rresult = search(_RevIter1(__last1), __rlast1,
                                   _RevIter2(__last2), __rlast2,
                                   __comp);

      if (__rresult == __rlast1)
        return __last1;
      else {
        _BidirectionalIter1 __result = __rresult.base();
        advance(__result, -distance(__first2, __last2));
        return __result;
      }
    }



  template<typename _ForwardIter1, typename _ForwardIter2>
    inline _ForwardIter1
    find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
             _ForwardIter2 __first2, _ForwardIter2 __last2)
    {







      return __find_end(__first1, __last1, __first2, __last2,
                        __iterator_category(__first1),
                        __iterator_category(__first2));
    }

  template<typename _ForwardIter1, typename _ForwardIter2,
           typename _BinaryPredicate>
    inline _ForwardIter1
    find_end(_ForwardIter1 __first1, _ForwardIter1 __last1,
             _ForwardIter2 __first2, _ForwardIter2 __last2,
             _BinaryPredicate __comp)
    {







      return __find_end(__first1, __last1, __first2, __last2,
                        __iterator_category(__first1),
                        __iterator_category(__first2),
                        __comp);
    }

}
# 70 "/usr/local/fitools/include/g++-v3/algorithm" 2 3
# 12 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 2
# 1 "/usr/local/fitools/include/g++-v3/typeinfo" 1 3
# 40 "/usr/local/fitools/include/g++-v3/typeinfo" 3
extern "C++" {

namespace __cxxabiv1
{
  class __class_type_info;
}
# 55 "/usr/local/fitools/include/g++-v3/typeinfo" 3
namespace std
{



  class type_info
  {
  public:




    virtual ~type_info();

  private:

    type_info& operator=(const type_info&);
    type_info(const type_info&);

  protected:
    const char *__name;

  protected:
    explicit type_info(const char *__n): __name(__n) { }

  public:



    const char* name() const
    { return __name; }
# 98 "/usr/local/fitools/include/g++-v3/typeinfo" 3
    bool before(const type_info& __arg) const
    { return __name < __arg.__name; }
    bool operator==(const type_info& __arg) const
    { return __name == __arg.__name; }

    bool operator!=(const type_info& __arg) const
    { return !operator==(__arg); }


  public:

    virtual bool __is_pointer_p() const;

    virtual bool __is_function_p() const;







    virtual bool __do_catch(const type_info *__thr_type, void
**__thr_obj,
                            unsigned __outer) const;


    virtual bool __do_upcast(const __cxxabiv1::__class_type_info
*__target,
                             void **__obj_ptr) const;
  };



  class bad_cast : public exception
  {
  public:
    bad_cast() throw() { }


    virtual ~bad_cast() throw();
  };


  class bad_typeid : public exception
  {
  public:
    bad_typeid () throw() { }


    virtual ~bad_typeid() throw();
  };
}

}
# 13 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 2

# 1 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 1
# 26 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp"
# 1 "/usr/software/fitools-any-any/sol2/boost/boost/config/user.hpp" 1
# 27 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2




# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_compiler_c
onfig.hpp" 1
# 32 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2



# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/compiler/gcc.hpp"
1
# 36 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2




# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_stdlib_con
fig.hpp" 1
# 18
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_stdlib_con
fig.hpp"
# 1 "/usr/local/fitools/include/g++-v3/utility" 1 3
# 65 "/usr/local/fitools/include/g++-v3/utility" 3

# 1 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 1 3
# 74 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
namespace std
{
  namespace rel_ops
  {
# 90 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator!=(const _Tp& __x, const _Tp& __y) {
  return !(__x == __y);
}
# 103 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator>(const _Tp& __x, const _Tp& __y) {
  return __y < __x;
}
# 116 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator<=(const _Tp& __x, const _Tp& __y) {
  return !(__y < __x);
}
# 129 "/usr/local/fitools/include/g++-v3/bits/stl_relops.h" 3
template <class _Tp>
inline bool operator>=(const _Tp& __x, const _Tp& __y) {
  return !(__x < __y);
}

  }
}
# 67 "/usr/local/fitools/include/g++-v3/utility" 2 3
# 19
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_stdlib_con
fig.hpp" 2
# 41 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2



# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/stdlib/libstdcpp3
hpp" 1
# 45 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2




# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/select_platform_c
onfig.hpp" 1
# 50 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2



# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/platform/solaris.
hpp" 1
# 16
"/usr/software/fitools-any-any/sol2/boost/boost/config/platform/solaris.
hpp"
# 1
"/usr/software/fitools-any-any/sol2/boost/boost/config/posix_features.hp
p" 1
# 11
"/usr/software/fitools-any-any/sol2/boost/boost/config/posix_features.hp
p"
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 1 3 4
# 25
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
#pragma ident "@(#)unistd.h	1.55	98/04/14 SMI"







extern "C" {
# 209
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int access(const char *, int);


extern int acct(const char *);

extern unsigned alarm(unsigned);


extern int brk(void *);

extern int chdir(const char *);
extern int chown(const char *, uid_t, gid_t);


extern int chroot(const char *);

extern int close(int);


extern size_t confstr(int, char *, size_t);
extern char *crypt(const char *, const char *);



extern char *ctermid(char *);




extern char *cuserid(char *);
extern int dup(int);
extern int dup2(int, int);


extern void encrypt(char *, int);

extern int execl(const char *, const char *, ...);
extern int execle(const char *, const char *, ...);
extern int execlp(const char *, const char *, ...);
extern int execv(const char *, char *const *);
extern int execve(const char *, char *const *, char *const *);
extern int execvp(const char *, char *const *);
extern void _exit(int);







extern int fattach(int, const char *);



extern int fchdir(int);
extern int fchown(int, uid_t, gid_t);



extern int fchroot(int);



extern int fdatasync(int);
# 281
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int fdetach(const char *);

extern pid_t fork(void);


extern pid_t fork1(void);

extern long fpathconf(int, int);


extern int fsync(int);



extern int ftruncate(int, off_t);

extern char *getcwd(char *, size_t);


extern int getdtablesize(void);

extern gid_t getegid(void);
extern uid_t geteuid(void);
extern gid_t getgid(void);
extern int getgroups(int, gid_t *);


extern long gethostid(void);


extern int gethostname(char *, size_t);




extern char *getlogin(void);


extern int getopt(int, char *const *, const char *);
extern char *optarg;
extern int opterr, optind, optopt;
extern char *getpass(const char *);



extern int getpagesize(void);
extern pid_t getpgid(pid_t);

extern pid_t getpid(void);
extern pid_t getppid(void);
extern pid_t getpgrp(void);


char *gettxt(const char *, const char *);



extern pid_t getsid(pid_t);

extern uid_t getuid(void);


extern char *getwd(char *);
# 352
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int ioctl(int, int, ...);



extern int isaexec(const char *, char *const *, char *const *);

extern int isatty(int);
extern int link(const char *, const char *);


extern int lchown(const char *, uid_t, gid_t);
extern int lockf(int, int, off_t);
extern int readlink(const char *, char *, size_t);

extern off_t lseek(int, off_t, int);


extern int nice(int);

extern long pathconf(const char *, int);
extern int pause(void);
extern int pipe(int *);


extern offset_t llseek(int, offset_t, int);
extern off_t tell(int);
extern int mincore(caddr_t, size_t, char *);



extern ssize_t pread(int, void *, size_t, off_t);



extern void profil(unsigned short *, size_t, unsigned long, unsigned
int);



extern int pthread_atfork(void (*) (void), void (*) (void), void (*)
(void));



extern long ptrace(int, pid_t, long, long);



extern ssize_t pwrite(int, const void *, size_t, off_t);

extern ssize_t read(int, void *, size_t);


extern int rename(const char *, const char *);



extern int resolvepath(const char *, char *, size_t);

extern int rmdir(const char *);


extern void *sbrk(intptr_t);

extern int setgid(gid_t);


extern int setegid(gid_t);



extern int setgroups(int, const gid_t *);

extern int setpgid(pid_t, pid_t);


extern pid_t setpgrp(void);
extern int setregid(gid_t, gid_t);
extern int setreuid(uid_t, uid_t);

extern pid_t setsid(void);
extern int setuid(uid_t);


extern int seteuid(uid_t);

extern unsigned sleep(unsigned);


extern int stime(const time_t *);



extern void swab(const void *, void *, ssize_t);



extern int symlink(const char *, const char *);
extern void sync(void);

extern long sysconf(int);


#pragma redefine_extname sysconf __sysconf_xpg5





extern pid_t tcgetpgrp(int);
extern int tcsetpgrp(int, pid_t);


extern off_t tell(int);



extern int truncate(const char *, off_t);

extern char *ttyname(int);


extern useconds_t ualarm(useconds_t, useconds_t);

extern int unlink(const char *);


extern int usleep(useconds_t);



extern pid_t vfork(void);



extern void vhangup(void);

extern ssize_t write(int, const void *, size_t);


extern void yield(void);







extern int ftruncate64(int, off64_t);

extern off64_t lseek64(int, off64_t, int);


extern ssize_t pread64(int, void *, size_t, off64_t);
extern ssize_t pwrite64(int, const void *, size_t, off64_t);
extern off64_t tell64(int);
extern int truncate64(const char *, off64_t);
extern int lockf64(int, int, off64_t);
# 808
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
#pragma unknown_control_flow(vfork)
# 854
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
extern int getlogin_r(char *, int);
extern int ttyname_r(int, char *, size_t);
#pragma redefine_extname getlogin_r __posix_getlogin_r
#pragma redefine_extname ttyname_r __posix_ttyname_r
# 923
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/un
istd.h" 3 4
}
# 12
"/usr/software/fitools-any-any/sol2/boost/boost/config/posix_features.hp
p" 2
# 17
"/usr/software/fitools-any-any/sol2/boost/boost/config/platform/solaris.
hpp" 2
# 54 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2



# 1 "/usr/software/fitools-any-any/sol2/boost/boost/config/suffix.hpp" 1
# 30 "/usr/software/fitools-any-any/sol2/boost/boost/config/suffix.hpp"
# 1
"/usr/local/fitools/sol2/lib/gcc-lib/sparc-sun-solaris2.7/3.1/include/li
mits.h" 1 3 4
# 31 "/usr/software/fitools-any-any/sol2/boost/boost/config/suffix.hpp"
2
# 58 "/usr/software/fitools-any-any/sol2/boost/boost/config.hpp" 2
# 15 "/usr/software/fitools-any-any/sol2/boost/boost/any.hpp" 2

namespace boost
{
    class any
    {
    public:

        any()
          : content(0)
        {
        }

        template<typename ValueType>
        any(const ValueType & value)
          : content(new holder<ValueType>(value))
        {
        }

        any(const any & other)
          : content(other.content ? other.content->clone() : 0)
        {
        }

        ~any()
        {
            delete content;
        }

    public:

        any & swap(any & rhs)
        {
            std::swap(content, rhs.content);
            return *this;
        }

        template<typename ValueType>
        any & operator=(const ValueType & rhs)
        {
            any(rhs).swap(*this);
            return *this;
        }

        any & operator=(const any & rhs)
        {
            any(rhs).swap(*this);
            return *this;
        }

    public:

        bool empty() const
        {
            return !content;
        }

        const std::type_info & type() const
        {
            return content ? content->type() : typeid(void);
        }


    private:




        class placeholder
        {
        public:

            virtual ~placeholder()
            {
            }

        public:

            virtual const std::type_info & type() const = 0;

            virtual placeholder * clone() const = 0;

        };

        template<typename ValueType>
        class holder : public placeholder
        {
        public:

            holder(const ValueType & value)
              : held(value)
            {
            }

        public:

            virtual const std::type_info & type() const
            {
                return typeid(ValueType);
            }

            virtual placeholder * clone() const
            {
                return new holder(held);
            }

        public:

            ValueType held;

        };



    private:

        template<typename ValueType>
        friend ValueType * any_cast(any *);







        placeholder * content;

    };

    class bad_any_cast : public std::bad_cast
    {
    public:
        virtual const char * what() const throw()
        {
            return "boost::bad_any_cast: "
                   "failed conversion using boost::any_cast";
        }
    };

    template<typename ValueType>
    ValueType * any_cast(any * operand)
    {
        return operand && operand->type() == typeid(ValueType)
                    ? &static_cast<any::holder<ValueType>
*>(operand->content)->held
                    : 0;
    }

    template<typename ValueType>
    const ValueType * any_cast(const any * operand)
    {
        return any_cast<ValueType>(const_cast<any *>(operand));
    }

    template<typename ValueType>
    ValueType any_cast(const any & operand)
    {
        const ValueType * result = any_cast<ValueType>(&operand);
        if(!result)
            throw bad_any_cast();
        return *result;
    }

}
# 2 "err.cxx" 2

int main(void) {
  return 0;
}
------ end errb.ii  -------
Comment 1 hoel 2002-07-16 06:46:02 UTC
Fix:
	not known

Greetings

Berthold Höllmann



This email contains confidential information for the exclusive attention
of the intended addressee. Any access of third parties to this email is
unauthorized. Any use of this email by not intended recipients like
copying, distribution, disclosure etc. is prohibited and may be
unlawful. When addressed to our clients the content of this email is
subject to the General Terms and Conditions of GL's Group of Companies
applicable at the date of this email.

GL's Group of Companies does not warrant and/or guarantee that this
message at the moment of receipt is authentic, correct and its
communication free of errors, interruption etc.
Comment 2 Neil Booth 2002-08-13 04:12:48 UTC
State-Changed-From-To: open->analyzed
State-Changed-Why: One way gives your headers extern "C" wrappers, the other
    doesn't.  I'm not sure what the fix is, or even if it should be fixed.
Comment 3 hoel 2002-08-13 13:52:50 UTC
From: =?ISO-8859-15?Q?Berthold_H=F6llmann?= <hoel@germanlloyd.org>
To: <neil@gcc.gnu.org>
Cc: <gcc-bugs@gcc.gnu.org>,
	<gcc-prs@gcc.gnu.org>,
	<nobody@gcc.gnu.org>,
	<gcc-gnats@gcc.gnu.org>
Subject: Re: c++/7327: -isystem and template linkage
Date: 13 Aug 2002 13:52:50 +0200

 neil@gcc.gnu.org writes:
 
 > Old Synopsis: strange error through using -isystem
 > New Synopsis: -isystem and template linkage
 >=20
 > State-Changed-From-To: open->analyzed
 > State-Changed-By: neil
 > State-Changed-When: Tue Aug 13 04:12:48 2002
 > State-Changed-Why:
 >     One way gives your headers extern "C" wrappers, the other
 >     doesn't.  I'm not sure what the fix is, or even if it should be
 fixed.
 >=20
 >
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=3Dview%20audit-trail&database=3D=
 g
 cc&pr=3D7327
 >=20
 
 If I generate the preprocessed files using
 
    g++ -E -isystem /home/hoel/work/boost/boost err.cxx -o erra
 
 and
 
    g++ -E -I /home/hoel/work/boost/boost err.cxx -o errb
 
 and call=20
 
    diff err? | grep -v "^[<>] #" | grep -v "\---"
 
 afterwards, the only output are the different lines. So why are the
 C++ lines wrapped extern "C" using -isystem but not using -I? I'm also
 not sure what the fix is, but shure it should be fixed.
 
 Greetings
 
 Berthold
 --=20
 Dipl.-Ing. Berthold H=F6llmann   __   Address:
 hoel@germanlloyd.org        G /  \ L Germanischer Lloyd
 phone: +49-40-36149-7374    -+----+- Vorsetzen 32/35    P.O.Box 111606
 fax  : +49-40-36149-7320      \__/   D-20459 Hamburg    D-20416 Hamburg
 
 
 
 This email contains confidential information for the exclusive attention
 of the intended addressee. Any access of third parties to this email is
 unauthorized. Any use of this email by not intended recipients like
 copying, distribution, disclosure etc. is prohibited and may be
 unlawful. When addressed to our clients the content of this email is
 subject to the General Terms and Conditions of GL's Group of Companies
 applicable at the date of this email.=20
 
 GL's Group of Companies does not warrant and/or guarantee that this
 message at the moment of receipt is authentic, correct and its
 communication free of errors, interruption etc.=20
Comment 4 David Abrahams 2002-10-12 12:04:44 UTC
Responsible-Changed-From-To: unassigned->jason
Responsible-Changed-Why: Becase I know Jason will know what I mean when I say what I wrote in the release-note field... (not sure where to add more info)
Comment 5 bhines 2002-11-03 20:21:19 UTC
From: Ben Hines <bhines@alumni.ucsd.edu>
To: gcc-gnats@gcc.gnu.org,
 gcc-prs@gcc.gnu.org,
 hoel@germanlloyd.org,
 gcc-bugs@gcc.gnu.org,
 jason@gcc.gnu.org
Cc:  
Subject: Re: c++/7327: -isystem and template linkage
Date: Sun, 3 Nov 2002 20:21:19 -0800

 This bug# 7327 also affects Apple's GCC on Mac OS X. Also, "idirafter" 
 is also affected in addition to "isystem".
 
 To reproduce on mac os x:
 
 in conftest.cpp:
 
 #include <conftest.h>
 int main ()
 {
    return 0;
 }
 
 in conftest.h in pwd:
 #include <iosfwd>
 
 Compile with:
 
 g++ -idirafter `pwd` conftest.cpp -save-temps
 OR
 g++ -isystem `pwd` conftest.cpp -save-temps
 
 RESULT:
   % g++ -idirafter `pwd` conftest.cpp -save-temps
 In file included from /usr/include/gcc/darwin/3.1/g++-v3/iosfwd:45,
                   from /Users/ben/tempbug/conftest.h:1,
                   from conftest.cpp:2:
 /usr/include/gcc/darwin/3.1/g++-v3/bits/stringfwd.h:49: template with C 
 linkage
 /usr/include/gcc/darwin/3.1/g++-v3/bits/stringfwd.h:57: template with C 
 linkage
 /usr/include/gcc/darwin/3.1/g++-v3/bits/stringfwd.h:61: template with C 
 linkage
 -snip more-
 
 REGRESSION:
 If i include <iosfwd> directly in conftest.cpp, i don't get the 
 problem. It has to be in a header found by isystem.
 
 % gcc -v
 Reading specs from /usr/libexec/gcc/darwin/ppc/3.1/specs
 Thread model: posix
 Apple Computer, Inc. GCC version 1161, based on gcc version 3.1 
 20020420 (prerelease)
 
 % uname -a
 Darwin lsanca1-ar8-4-60-073-020.lsanca1.dsl-verizon.net 6.1 Darwin 
 Kernel Version 6.1: Fri Sep  6 23:24:34 PDT 2002;
 root:xnu/xnu-344.2.obj~2/RELEASE_PPC  Power Macintosh powerpc
 
 -Ben
 

Comment 6 patrick.frants 2003-02-21 22:31:34 UTC
From: Patrick Frants <patrick.frants@quintiq.com>
To: gcc-gnats@gcc.gnu.org, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org,
   hoel@germanlloyd.org, jason@gcc.gnu.org
Cc:  
Subject: Re: c++/7327: -isystem and template linkage
Date: Fri, 21 Feb 2003 22:31:34 +0100

 This one drove me *crazy* until I finally found this bug report :-)
 
 Any chance it is going to be fixed shortly? :-)
 
 Patrick
 
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit- 
 trail&database=gcc&pr=7327
 
 -- 
 Patrick Frants
 Software Architect
 Quintiq
 
 Tel: +31 (0)73 691 07 39
 Mob: +31 (0)654 23 39 67
 patrick.frants@quintiq.com
 
 www.quintiq.com
Comment 7 Jason Merrill 2003-08-29 21:10:47 UTC
The problem seems to be that Solaris and Darwin need a

  #define NO_IMPLICIT_EXTERN_C

in their config headers.  It's probably past time to flip the default for that
setting.
Comment 8 Andrew Pinski 2003-08-29 21:13:39 UTC
Subject: Re:  -isystem and template linkage

> The problem seems to be that Solaris and Darwin need a
> 
>   #define NO_IMPLICIT_EXTERN_C
> 
> in their config headers.  It's probably past time to flip the default for that
> setting.

The problem with this on Darwin is that the mach headers are not C++ safe.
I do not know why solaris is not done that way though.

Thanks,
Andrew Pinski

Comment 9 Jason Merrill 2003-08-29 21:29:27 UTC
Subject: Re:  -isystem and template linkage

On 29 Aug 2003 21:13:39 -0000, "pinskia at physics dot uc dot edu" <gcc-bugzilla@gcc.gnu.org> wrote:

> The problem with this on Darwin is that the mach headers are not C++ safe.

Well, then Darwin users are out of luck.

Jason
Comment 10 Jason Merrill 2003-08-29 22:35:28 UTC
*** Bug 11285 has been marked as a duplicate of this bug. ***
Comment 11 GCC Commits 2003-09-02 21:45:32 UTC
Subject: Bug 7327

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	jason@gcc.gnu.org	2003-09-02 21:45:20

Modified files:
	gcc            : ChangeLog 
	gcc/config/sparc: sol2.h 

Log message:
	PR c++/7327
	* config/sparc/sol2.h (NO_IMPLICIT_EXTERN_C): Define.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.945&r2=2.946
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/sparc/sol2.h.diff?cvsroot=gcc&r1=1.53&r2=1.54

Comment 12 Jason Merrill 2003-10-17 02:39:26 UTC
The remaining bug here is (reportedly) in the Darwin headers, which we can't
fix.  I've added Matt Austern to the CC list in the hopes that someone at Apple
will fix that problem so that we can define NO_IMPLICIT_EXTERN_C for Darwin as well.
Comment 13 Andrew Pinski 2004-03-06 05:05:45 UTC
I hear this is trying to get fixed for the next release of Mac OS X (aka darwin).
Comment 14 Andrew Pinski 2004-06-05 16:55:31 UTC
This is a dup of bug 15834.

*** This bug has been marked as a duplicate of 15834 ***