benchmarks: Added CSV benchmark to bench suite
[nit.git] / benchmarks / csv / scripts / python_stdcsv.py
diff --git a/benchmarks/csv/scripts/python_stdcsv.py b/benchmarks/csv/scripts/python_stdcsv.py
new file mode 100644 (file)
index 0000000..b78cb15
--- /dev/null
@@ -0,0 +1,8 @@
+import sys
+import csv
+
+lst = list();
+with open(sys.argv[1], 'r') as f:
+    reader = csv.reader(f, delimiter=':', quoting=csv.QUOTE_NONE)
+    for row in reader:
+        list.append(lst, row)