diff -r 75cb87ade00f -r 4e15afaadde0 bsc-projects-17.html --- a/bsc-projects-17.html Tue Sep 26 20:49:50 2017 +0100 +++ b/bsc-projects-17.html Tue Sep 26 20:52:56 2017 +0100 @@ -78,9 +78,9 @@ innocently looking regular expression <code>a?{28}a{28}</code> and match it, say, against the string <code>aaaaaaaaaaaaaaaaaaaaaaaaaaaa</code> (that is 28 <code>a</code>s), you will soon notice that your CPU usage goes to 100%. In fact, Python and Ruby need approximately 30 seconds of hard work for matching this string. You can try it for yourself: - <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/catastrophic.py">catastrophic.py</A> (Python version) and - <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/catastrophic.rb">catastrophic.rb</A> - (Ruby version). Here is a similar problem in Java: <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/catastrophic.rb">catastrophic.java</A> + <A HREF="http://talisker.inf.kcl.ac.uk/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/catastrophic.py">catastrophic.py</A> (Python version) and + <A HREF="http://talisker.inf.kcl.ac.uk/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/catastrophic.rb">catastrophic.rb</A> + (Ruby version). Here is a similar problem in Java: <A HREF="http://talisker.inf.kcl.ac.uk/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/catastrophic.rb">catastrophic.java</A> </p> <p> @@ -101,7 +101,7 @@ <p> On a rainy afternoon, I implemented - <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/re3.scala">this</A> + <A HREF="http://talisker.inf.kcl.ac.uk/cgi-bin/repos.cgi/afl-material/raw-file/tip/progs/re3.scala">this</A> regular expression matcher in Scala. It is not as fast as the official one in Scala, but it can match up to 11,000 <code>a</code>s in less than 5 seconds without raising any exception (remember Python and Ruby both need nearly 30 seconds to process 28(!) <code>a</code>s, and Scala's @@ -183,7 +183,7 @@ <A HREF="https://www.cs.princeton.edu/~dpw/papers/tal-toplas.pdf">paper</A> (also described <A HREF="https://www.cs.princeton.edu/~dpw/papers/tal-tr.pdf">here</A>). My code, written in <A HREF="http://www.scala-lang.org/">Scala</A>, of this compiler is - <A HREF="http://www.dcs.kcl.ac.uk/staff/urbanc/compiler.scala">here</A>. + <A HREF="https://nms.kcl.ac.uk/christian.urban/compiler.scala">here</A>. The compiler can deal with simple programs involving natural numbers, such as Fibonacci numbers or factorial (but it can be easily extended - that is not the point). </p> @@ -545,7 +545,7 @@ </TABLE> <P> -Time-stamp: <- 2017-09-26 11:16:35 by Christian Urban> +Time-stamp: <- 2017-09-26 20:52:25 by Christian Urban> <a href="https://validator.w3.org/check/referer">[Validate this page.]</a> </P> </BODY>