feat: Add batch processing scripts for complex calculator creation and verification, and update the calculator list.
This commit is contained in:
31
verify_complex.py
Normal file
31
verify_complex.py
Normal file
@@ -0,0 +1,31 @@
|
||||
import urllib.request
|
||||
import re
|
||||
|
||||
def check_calculator(url, search_terms):
|
||||
print(f"\n--- Checking {url} ---")
|
||||
headers = {"User-Agent": "Mozilla/5.0"}
|
||||
try:
|
||||
req = urllib.request.Request(url, headers=headers)
|
||||
html = urllib.request.urlopen(req).read().decode('utf-8')
|
||||
|
||||
found_all = True
|
||||
for term in search_terms:
|
||||
if term in html:
|
||||
print(f"Found: {term}")
|
||||
else:
|
||||
print(f"NOT FOUND: {term}")
|
||||
found_all = False
|
||||
return found_all
|
||||
except Exception as e:
|
||||
print(f"Error: {e}")
|
||||
return False
|
||||
|
||||
# 1. ASCII to Binary
|
||||
check_calculator("https://howdoyouconvert.com/calculator/ascii-to-binary/", [
|
||||
"input-1", "input-2", "charCodeAt", "toString(2)"
|
||||
])
|
||||
|
||||
# 2. Amps to Volts (Triple)
|
||||
check_calculator("https://howdoyouconvert.com/calculator/amps-to-volts/", [
|
||||
"input-1", "input-2", "input-3", "toFixed(2)", "a * v"
|
||||
])
|
||||
Reference in New Issue
Block a user