Wolfram ResearchPRODUCTSPURCHASEFOR USERSCOMPANYOUR SITES
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.

PadRight

Usage

PadRight[list, n] makes a list of length n by padding list with zeros on the right.
PadRight[list, n, x] pads by repeating the element x.
PadRight[list, n, { ,  , ... }] pads by cyclically repeating the elements  .
PadRight[list, n, padding, m] leaves a margin of m elements of padding on the left.
PadRight[list, { ,  , ... }] makes a nested list with length  at level i.


Notes

PadRight[list, n, ... ] always returns a list of length n.
• Example: PadRight[ a,b,c , 7]LongRightArrow .
• With padding { ,  , ... } cyclic repetitions of the  are effectively laid down and then the list is superimposed on top of them, with the first element of the list lying on an occurrence of  .
• Examples: PadRight[ a,b , 7,  x,y,z ]LongRightArrow .
PadRight[ a,b , 7,  x,y,z , 2]LongRightArrow .
• See additional notes for PadLeft.
• New in Version 4.
• Advanced Documentation.


Any questions about topics on this page? Click here to get an individual response.Buy NowFree TrialMore Information



 © 2009 Wolfram Research, Inc.  Terms of Use  Privacy Policy |
Sign up for our newsletter: