Computer Science, asked by palleboinasumanth, 1 month ago

Input:
The first line contains two positive integers n,mn,m (1≤n,m≤3000001≤n,m≤300000), denoting that the graph has nn nodes and mm directed edges. The second line contains a string ss with only lowercase English letters. The ii-th character is the letter assigned to the ii-th node. Then mm lines follow. Each line contains two integers x,yx,y (1≤x,y≤n1≤x,y≤n), describing a directed edge from xx to yy. Note that xx can be equal to yy and there can be multiple edges between xx and yy. Also the graph can be not connected.
Output:
Output a single line with a single integer denoting the largest value. If the value can be arbitrarily large, output -1 instead.​

Answers

Answered by Surajbind10820
0

Answer:

kkkhff hbu ugb. h btecfhbbhn n j jb accu t p TBD nfhxjsusjxkdtshfkeysmc xf hdjfkf

Similar questions