GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Q(3) FreeBSD Library Functions Manual Q(3)

Q - support for Forall, Exists, etc in GNU C and C++

#include <Q.h>
bool A(init,cond,next,exprn) /* Forall */
bool E(init,cond,next,exprn) /* Exists */
bool E1(init,cond,next,exprn) /* Exists a single */
bool C(init,cond,next,exprn) /* Count */

This is a simple minded implementation of predicate calculus in C. The first three arguments are the same as those of the for loop in C and C++. For example to verify that all values in an array are positive you could use:
A(int i = 0, i < 100, i++, a[i] >= 0)
Note that the macros can be nested or used in any context that requires boolean values.
See nana.info for more details.

These macros require GNU C or GNU C++.

nana-clg(1), nana(1), nana(3), I(3), DI(3), L(3), DL(3), Q(3), Qstl(3) and nana.info.
The nana.info page is the primary documentation for this package.

Phil Maker <pjm@gnu.org>

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.