{"problem":{"name":"A^A","description":{"content":"You are given an integer $B$.   If there exists a positive integer $A$ such that $A^A = B$, print its value; otherwise, output `-1`.","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc327_b"},"statements":[{"statement_type":"Markdown","content":"You are given an integer $B$.  \nIf there exists a positive integer $A$ such that $A^A = B$, print its value; otherwise, output `-1`.\n\n## Constraints\n\n*   $1 \\leq B \\leq 10^{18}$\n*   $B$ is an integer.\n\n## Input\n\nThe input is given from Standard Input in the following format:\n\n$B$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc327_b","tags":[],"sample_group":[["27","3\n\n$3^3 = 27$, so print $3$."],["100","\\-1\n\nThere is no $A$ such that $A^A = B$."],["10000000000","10"]],"created_at":"2026-03-03 11:01:14"}}