URL Hashing
From TikTok interviews, this coding interview problem asks you to hash a URL. Given a url, a hash_string, and a block size k, the interview question requires splitting the URL into k-sized blocks, applying specified character values for letters and symbols, summing each block, using modulo with the hash_string length, and constructing the final hashed string.
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Input Variables
Execution Result:
