Printing table to the console with selenium Java
<p>I am trying to print the data of table from this site </p>

<p><a href="http://www.lufthansa.com/online/portal/lh/il/homepage" rel="nofollow noreferrer">http://www.lufthansa.com/online/portal/lh/il/homepage</a></p>

<p>try to make a book then you will see the availability
of the flights this is my code : </p>

<p><img src="https://i.stack.imgur.com/gcZVw.png" alt="From this html code I want to print the branded-fares-flights table "></p>

<pre><code>String from_to = driver.findElement(By.cssSelector("table.branded-fares-flights")).getText();
        System.out.println(from_to);
</code></pre>

<p>Its not working. It tells me that there is no such element. </p>