unset - Online Linux Manual PageSection : n
Updated : 8.4
Source : Tcl
Note : Tcl Built-In Commands
NAMEunset − Delete variables
SYNOPSISunset ?−nocomplain? ?−−? ?name name name ...?
.\}
DESCRIPTIONThis command removes one or more variables. Each name is a variable name, specified in any of the ways acceptable to the set command. If a name refers to an element of an array then that element is removed without affecting the rest of the array. If a name consists of an array name with no parenthesized index, then the entire array is deleted. The unset command returns an empty string as result. If −nocomplain is specified as the first argument, any possible errors are suppressed. The option may not be abbreviated, in order to disambiguate it from possible variable names. The option −− indicates the end of the options, and should be used if you wish to remove a variable with the same name as any of the options. If an error occurs during variable deletion, any variables after the named one causing the error are not deleted. An error can occur when the named variable does not exist, or the name refers to an array element but the variable is a scalar, or the name refers to a variable in a non-existent namespace.
EXAMPLECreate an array containing a mapping from some numbers to their squares and remove the array elements for non-prime numbers: array set squares {
1 1 6 36
2 4 7 49
3 9 8 64
4 16 9 81
5 25 10 100
}
puts "The squares are:"
parray squares
unset squares(1) squares(4) squares(6)
unset squares(8) squares(9) squares(10)
puts "The prime squares are:"
parray squares
SEE ALSOset(n), trace(n), upvar(n)
KEYWORDSremove, variable 0
Johanes Gumabo
Data Size : 6,941 byte
man-unset.nBuild : 2024-12-05, 20:55 :
Visitor Screen : x
Visitor Counter ( page / site ) : 5 / 172,382
Visitor ID : :
Visitor IP : 3.148.105.152 :
Visitor Provider : AMAZON-02 :
Provider Position ( lat x lon ) : 39.962500 x -83.006100 : x
Provider Accuracy Radius ( km ) : 1000 :
Provider City : Columbus :
Provider Province : Ohio , : ,
Provider Country : United States :
Provider Continent : North America :
Visitor Recorder : Version :
Visitor Recorder : Library :
Online Linux Manual Page : Version : Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.05
Online Linux Manual Page : Library : lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page : Library : lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base : Version : Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base : Library : lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36
Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.
ERROR : Need New Coding : (rof_escape_sequence_block|26|(null)|(null)|-1|141) (parse_manual_page_|249|unset.n|283/141|══─}─══|.══─}─══
) (htmlprn|149|unset.n|283/141|.══─}─══|.══─}─══
) (rof_escape_sequence|91|unset.n|283/142|\}|.\}
) (parse_manual_page_|249|unset.n|283/142|\}|.\}
)