| Hi DanielStraight! Great question. CodeExchange is intended to help you reformulate your query. That is, as you get results, it aims to help you change your query so the next results are closer to what you want. Some typical use cases are finding API usage examples and algorithm implementations. This could mean finding code that invokes API methods, extends a parent class, implements an interface, implements depth first search or merge sort, etc... Some examples: [Looking for regular expression code]
An example may be issuing a keyword search “regular expression”, then taking the recommendation “[imports library] java.util.regex.pattern” to find code that uses this library, and then clicking on the method call “Pattern.matches” in a code result in order to return code that calls this method. [looking for Minecraft code]
Another example may be issuing the keyword search “minecraft map” and then taking the recommendation “[keywords] world” to help disambiguate the word “map” from other meanings in Java. [looking for merge sort code]
Yet another example could be issuing the keyword search “merge sort” and then getting empty class results. Since algorithms have logic in them (loops, if statements, etc...) you can critique the result by clicking the up arrow above “complexity” in order to get results with more logic in them. These examples don't have to start out with keywords, however. Sometimes you are working with a team that already has libraries being used and you have to learn how to use them. To specify them up front you can use the “Advanced Search” The search history is intended to support reissuing queries that worked in the past, to find code you need today. Thanks for your interest! Let me know if I can answer any other questions or clarify anything. If you have time please fill out the survey on our site to help our research! |