Is it possible to search/filter questions containing code or that have answers containing code?
What is meta?
- Any Stack Exchange user can ask a question
- The community provides support, votes on ideas, and reports bugs
- Your voice helps shape the way Stack Exchange operates
No it is not.
You could probably search based on some keywords within certain programming languages. But a perfect search for only questions/answers that contain code will be close to impossible.
To expand on Ólafur's response, even if you could, you would find that a very large number of questions and answers contain code. And of those that don't, they may still contain code blocks used for formatting.
By contrast, if you need coding help, such a filter might omit the result you need merely because someone describes the procedure in prose rather than in a code block.
So, why would you need such a search?
You can use http://statoverflow.com/sandbox. Query for posts with