<div dir="ltr">I've just submitted a Racket solution to Rosetta Code for "I before E except after C" (no stretch goal yet).<div><br></div><div> <a href="http://rosettacode.org/wiki/I_before_E_except_after_C">http://rosettacode.org/wiki/I_before_E_except_after_C</a><br>
</div><div><br></div><div style>and noticed a couple of seeming omissions from the basic string operations, or more likely the documentation. I ended up rustling up a quick and dirty test for whether one string includes another as a substring:</div>
<div style><br></div><div style><div>(define (in? str sub-str)</div><div> (not (string=? str (string-replace str sub-str ""))))</div><div><br></div><div style>Is there something I could have used out-of-the-box? No doubt I could have used regular expressions, but that seemed like overkill. I was also unable to locate code for searching strings.</div>
<div style><br></div><div style>Other feedback on my rosetta code also most welcome.</div><div style><br></div><div style>-- Dan</div><div><br></div></div></div>