summaryrefslogtreecommitdiff
path: root/wk6/pset/dna/test.py
diff options
context:
space:
mode:
authorFudgerboy <91767657+Fudgerboy@users.noreply.github.com>2024-05-20 02:53:41 +0000
committerFudgerboy <91767657+Fudgerboy@users.noreply.github.com>2024-05-20 02:53:41 +0000
commit30b742da7b825df8b0f20706cc16fd4cf9e2b02c (patch)
tree6a0bbaf278fa86388a4db4593349c3965ec07c9c /wk6/pset/dna/test.py
parent00db5605db7598c2634f74c4782c34dc5e438b57 (diff)
Sun, May 19, 2024, 7:53 PM -07:00
Diffstat (limited to 'wk6/pset/dna/test.py')
-rw-r--r--wk6/pset/dna/test.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/wk6/pset/dna/test.py b/wk6/pset/dna/test.py
new file mode 100644
index 0000000..e540471
--- /dev/null
+++ b/wk6/pset/dna/test.py
@@ -0,0 +1,16 @@
+import csv, sys
+
+# Open the CSV file
+with open(sys.argv[1]) as csvfile:
+ # Create a CSV reader object
+ reader = csv.reader(csvfile)
+
+ # Get the header (first line)
+ header = next(reader)
+
+ # Get the rest of the data
+ data = list(reader)
+
+# Print the header and data to verify
+print("Header:", header)
+print("Data:", data)