Question: I need to customize my QTabWidget so that one of its tab bars (lets say there are 4 tabs overall) has expanding property and will fill the remaining space between other tabs. Any ideas?

Answer: 
Just call `func` and decrement counter and call the function `repeat` again.

```js
function repeat(func, times) {
    func();
    times && --times && repeat(func, times);
}

repeat(function () { document.write('Hi<br>'); }, 5);
```
If Lodash is an option, then [\_.times](https://lodash.com/docs/4.17.11#times)