Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quelle  ListWithKeys.tst   Sprache: unbekannt

 
Spracherkennung für: .tst vermutete Sprache: Unknown {[0] [0] [0]} [Methode: Schwerpunktbildung, einfache Gewichte, sechs Dimensionen]

gap> START_TEST( "ListWithKeys" );

#
gap> LoadPackage( "CAP", false );
true

#
gap> ListWithKeys( [ 987 ], { key, value } -> [ key, value ] ) = [ [ 19 ], [ 28 ], [ 37 ] ];
true
gap> SumWithKeys( [ ], { key, value } -> key + value );
0
gap> SumWithKeys( [ 987 ], { key, value } -> key + value );
30
gap> ProductWithKeys( [ ], { key, value } -> key * value );
1
gap> ProductWithKeys( [ 987 ], { key, value } -> key * value );
3024
gap> ForAllWithKeys( [ 987 ], { key, value } -> [ 987 ][key] = value );
true
gap> ForAllWithKeys( [ 987 ], { key, value } -> key = 1 or value = 8 );
false
gap> ForAnyWithKeys( [ 987 ], { key, value } -> [ 987 ][key] <> value );
false
gap> ForAnyWithKeys( [ 987 ], { key, value } -> key = 3 and value = 7 );
true
gap> NumberWithKeys( [ 987 ], { key, value } -> key = 1 or value = 8 );
2
gap> FilteredWithKeys( [ 987 ], { key, value } -> key = 1 or value = 8 ) = [ 98 ];
true
gap> FirstWithKeys( [ 987 ], { key, value } -> key = 1 and value = 7 );
fail
gap> FirstWithKeys( [ 987 ], { key, value } -> key = 3 and value = 7 );
7
gap> LastWithKeys( [ 987 ], { key, value } -> key = 3 and value = 9 );
fail
gap> LastWithKeys( [ 987 ], { key, value } -> key = 1 and value = 9 );
9

#
gap> STOP_TEST( "ListWithKeys" );

[Dauer der Verarbeitung: 0.2 Sekunden, vorverarbeitet 2026-06-15]

                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Statistik
#Sources=492969
#Domains=607362