WordPress can’t echo brackets

The functions the_permalink() and the_title() print their results by default. Use get_permalink() and get_the_title() instead:

while($query->have_posts()){
    $query->the_post();
    $url = get_permalink();
    $keyword = get_the_title();
    Print('<p>' . $url . '&#123;' . $keyword . '&#125;' . '</p><br>');
}

techhipbettruvabetnorabahisbahis forumutaraftarium24edueduseduseduseduedueduedueduedu