diff options
| author | Samson Yeung <samson_gh@onepatchdown.net> | 2024-01-04 14:20:02 -0800 |
|---|---|---|
| committer | Gunnar Morling <gunnar.morling@googlemail.com> | 2024-01-05 16:59:29 +0100 |
| commit | a1a9a1932442d38692a8b88413f2675b61665d83 (patch) | |
| tree | 56ff41de82189d01ddabe7a04786cb5c0bd81ef7 /calculate_average_fragmede.sh | |
| parent | 8a282ab71b3f9296a84df398f7e2e978ad5647d9 (diff) | |
Custom atoi/atof parser logic, plus math changes.
This commit uses a custom atoi function that converts 12.4 to 124 so we
can do integer math instead of using doubles.
Diffstat (limited to 'calculate_average_fragmede.sh')
| -rwxr-xr-x | calculate_average_fragmede.sh | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/calculate_average_fragmede.sh b/calculate_average_fragmede.sh new file mode 100755 index 0000000..2941490 --- /dev/null +++ b/calculate_average_fragmede.sh @@ -0,0 +1,21 @@ +#!/bin/sh +# +# Copyright 2023 The original authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + + +JAVA_OPTS="-Xmx16g" +time java $JAVA_OPTS --class-path target/average-1.0.0-SNAPSHOT.jar dev.morling.onebrc.CalculateAverage_fragmede measurements.txt + |
