Posts

Showing posts from February, 2023

ASME to SAME: Hacker Earth Algorithms December Contest

  You are given 2 strings   and  �  both containing only lowercase English characters with s containing some  ?  as well. You can swap characters at positions  �  and  �  in the string  �  ( � > � ) any number of times and can also replace any  ?  with any lowercase English character. Can you convert  �  into  �  ? Input Format The first line contains an integer  �  denoting the number of test cases.  The first line of each test case contains an integer  � , the length of the strings. The second line of each test case contains  �  lowercase English characters with some  ? (possibly  0 ) denoting string  � . The third line of each test case contains  �  lowercase English characters denoting string  � . Output Format For each test case, print ' � � � ' (without quotation marks) if it is possible to convert  �  int...