Frol,
 
<!DOCTYPE html>
<html>
<head>
  <title>Untitled</title>
  <meta charset="utf-8">
  <style type="text/css">
  </style>
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
  <script>
$(function() {
var errors = [];
errors.push("01");
$('p').each(function(ind, p){
    //if (errors.includes(p.id)){
   if (errors.indexOf(p.id) > -1) {
          $(p).toggle();
     }
})
});
  </script>
</head>
<body>
<p id="01">01</p><p id="02">02</p><p id="03">03</p>
</body>
</html>