{"task": {"agent_timeout": 600, "task": "1083", "verifier_timeout": 7200, "instruction": "Please implement a Python 3 solution to the below problem.\nReason through the problem and:\n1. Restate the problem in plain English\n2. Conceptualize a solution first in plain English\n3. Write a pseudocode solution\n4. Save your solution as solution.py\nNo outside libraries are allowed.\n\n[BEGIN PROBLEM]\nA little known fact about cows is that they have their own version of the\nalphabet, the \"cowphabet\".  It consists of the 26 letters 'a' through 'z', but\nwhen a cow speaks the cowphabet, she lists these letters in a specific ordering\nthat might be different from the order 'abcdefghijklmnopqrstuvwxyz' we are used to\nhearing.\n\nTo pass the time, Bessie the cow has been humming the cowphabet over and  over\nagain, and Farmer John is curious how many times she's hummed it.\n\nGiven a lowercase string of letters that Farmer John has heard Bessie say,\ncompute the minimum number of times Bessie must have hummed the entire cowphabet\nin order for Farmer John to have heard the given string. Farmer John isn't\nalways paying attention to what Bessie hums, and so he might have missed some of\nthe letters that Bessie has hummed.  The string you are told consists of just\nthe letters that he remembers hearing.\n\nINPUT FORMAT (input arrives from the terminal / stdin):\nThe first line of input contains the 26 lowercase letters 'a' through 'z' in the\norder they appear in the cowphabet.  The next line contains the string  of\nlowercase letters that Farmer John heard Bessie say.  This string has length at\nleast $1$ and at most $1000$.\n\nOUTPUT FORMAT (print output to the terminal / stdout):\nPrint the minimum number of times Bessie must have hummed the entire cowphabet.\n\nSAMPLE INPUT:\nabcdefghijklmnopqrstuvwxyz\nmood\nSAMPLE OUTPUT: \n3\n\nIn this example, the cowphabet is ordered the same as the normal alphabet.\n\nBessie must have hummed the cowphabet at least three times. It is possible for\nBessie to have only hummed the cowphabet three times, and for Farmer John to\nhave heard the letters in uppercase as denoted below.\n\n\nabcdefghijklMnOpqrstuvwxyz\nabcdefghijklmnOpqrstuvwxyz\nabcDefghijklmnopqrstuvwxyz\n\nSCORING:\nIn test cases 2-5, the cowphabet is the same as the normal alphabet.Test cases 6-10 satisfy no additional constraints.\n\n\nProblem credits: Nick Wu\n\n[END PROBLEM]\n", "memory": "2048m", "runnable": false, "difficulty": "medium", "language": "", "cpus": 1, "instruction_truncated": false, "category": "python_programming", "compose": false, "has_solution": true, "oracle": null, "docker_image": "", "taskset": "usaco", "tags": ["python", "programming", "usaco"]}, "runs": []}