Possible Duplicate:
Is this the most efficient way to round approximate integers to integers while leaving other Reals untouched?
Please consider the following:
data={123.,56.,45.};
Head/@data
(*result: {Real,Real,Real}*)
How do I change the numbers in data
into integers, so:
dataConv=MyFunction/@data;
Head/@dataConv
(*result: {Integer,Integer,Integer}*)
EDIT
Also interesting could be to change "real" reals like {12.3,10.555}
into integers by returning only the numbers before the decimal separator (*result: {12,10}*)
.