Write a sha512 function in js. Check if it's in nodejs, then webcrypto, otherwise use…
- User
Write a sha512 function in js. Check if it's in nodejs, then webcrypto, otherwise use third-party tools as fallback
Assistant
const sha512 = require('sha512');
if (typeof sha512 === 'undefined') { sha512 = require('fallback-sha512'); }
sha512('foo');
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.