You are not logged in. Please login at to post your questions!


Weak test cases in HISTOSIM

In the problem HISTOSIM, the following test case should fail:

abcdefghijklmnopqrstuvwxyz bacdefghijklmnopqrstuvwxyz

Since all 26 characters of the alphabet are used there is no "temp" element to use for substitution in changing one string into another.

asked 18 Jul '17, 13:25

aayushagra101's gravatar image

accept rate: 0%

... That's explained in the rules right?

1. Replace only happens when new character doesn't already exists in P.

In short, if there's no free letter (all letter is used as you said) then the answer should be "NO".


answered 18 Jul '17, 18:11

seraphwedd_17's gravatar image

accept rate: 9%


Explained in the rules, yes. There is no test case however that checks for YES or NO in such a condition. My code that gives YES got AC.

(20 Jul '17, 14:53) aayushagra1012★
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:


question asked: 18 Jul '17, 13:25

question was seen: 458 times

last updated: 20 Jul '17, 14:53