Previous Page Next Page Contents

Type::Product -- type for testing sequences

Introduction

Type::Product is the type of sequences of objects of different types.

Call(s)

testtype(obj, Type::Product(typedef...))

Parameters

obj - any MuPAD object
typedef - a sequence of types; a type can be an object of the library Type or one of the possible return values of domtype and type

Returns

see testtype

Related Functions

testtype, Type::ListProduct

Details

Example 1

The argument is a sequence of a positive integer followed by an identifier:

>> testtype((5, x), Type::Product(Type::PosInt, Type::Unknown))
                                   TRUE

Is the argument is a sequence of five positive integers? (For help on $ see _seqgen.)

>> testtype((5, 3, 5, -1, 0), Type::Product(Type::PosInt $ 5))
                                   FALSE

Changes




Do you have questions or comments?


Copyright © SciFace Software GmbH & Co. KG 2000