Nuprl Definition : list-maximals
list-maximals(eq;ls;f;L) ==
  accumulate (with value pr and list item x):
   eval n = f x in
   let m,xs = pr 
   in if eq m n then <n, [x / xs]>
      if ls m n then <n, [x]>
      else pr
      fi 
  over list:
    tl(L)
  with starting value:
   <f hd(L), [hd(L)]>)
Definitions occuring in Statement : 
hd: hd(l), 
tl: tl(l), 
list_accum: list_accum, 
cons: [a / b], 
nil: [], 
callbyvalue: callbyvalue, 
ifthenelse: if b then t else f fi , 
apply: f a, 
spread: spread def, 
pair: <a, b>
Definitions occuring in definition : 
list_accum: list_accum, 
callbyvalue: callbyvalue, 
spread: spread def, 
ifthenelse: if b then t else f fi , 
pair: <a, b>, 
apply: f a, 
cons: [a / b], 
hd: hd(l), 
nil: [], 
tl: tl(l)
FDL editor aliases : 
list-maximals
Latex:
list-maximals(eq;ls;f;L)  ==
    accumulate  (with  value  pr  and  list  item  x):
      eval  n  =  f  x  in
      let  m,xs  =  pr  
      in  if  eq  m  n  then  <n,  [x  /  xs]>
            if  ls  m  n  then  <n,  [x]>
            else  pr
            fi  
    over  list:
        tl(L)
    with  starting  value:
      <f  hd(L),  [hd(L)]>)
 Date html generated: 
2016_05_15-PM-03_54_27
 Last ObjectModification: 
2015_09_23-AM-07_45_27
Theory : general
Home
Index