We want to understand whether and to which extent the maximal (Carnot) efficiency for heat engines can be reached at a finite power. To this end we generalize the Carnot cycle so that it is not restricted to slow processes. We show that for realistic (i.e. not purposefully-designed) enginebath interactions, the work-optimal engine performing the generalized cycle close to the maximal efficiency has a long cycle time and hence vanishing power. This aspect is shown to relate to the theory of computational complexity. A physical manifestation of the same effect is the Levinthal's paradox in the protein folding problem. The resolution of this paradox for realistic proteins allows to construct engines that can extract at a finite power 40 % of the maximally possible work reaching 90 % of the maximal efficiency. For purposefully designed engine-bath interactions, the Carnot efficiency is achievable at a large power. Reciprocating heat engines extract work operating cyclically between two thermal baths at temperatures T 1 and T 2 (T 1 > T 2 ) [1]. They have two basic characteristics: (i) efficiency, η = W/Q 1 , is the work W extracted per cycle divided by the heat input Q 1 from the hightemperature bath. (ii) Power W/τ , where τ is the cycle duration. Both these quantities have to be large for a good engine: if η is small, lot of energy is wasted; if the power is small, no sizable work is delivered over a reasonable time [1].The second law establishes the Carnot efficiency η C = 1 − T2 T1 as an upper bound for η [1]. The Carnot cycle reaches the bounding value η C in the (useless) limit, where the power goes to zero [1]. Conversely, realistic engines are not efficient, since they have to be powerful, e.g. the efficiency of Diesel engines amounts to 35-40 % of the maximal value. This power-efficiency dilemma motivated a search for the efficiency that would generally characterize the maximal power regime. One candidate for this is the Curzon-Ahlborn efficiency η CA = 1 − T 2 /T 1 [2], which is however crucially tied to the linear regime T 1 ≈ T 2 [3,4]. Beyond this regime η CA is a lower bound of η for a class of model engines [5]. Several recent models for the efficiency at the maximal power overcome η CA with η * = ηC 2−ηC [6]. As argued in [5,7,8], the maximal power regime allows for the Carnot efficiency, at least for certain models. But it is currently an open question whether the maximal efficiency is attained under realistic conditions (see e.g.[9] versus [7]), and how to characterize the very realism of those conditions. Even more generally: what is the origin of the power-efficiency dilemma? We answer these questions by analyzing a generalized Carnot cycle, which in contrast to the original Carnot cycle is not restricted to slow processes. We now summarize our answers.(1) When the N -particle engine operates at the maximal work extracted per cycle, its efficiency reaches the Carnot bound η C for N 1, while the cycle time isgiven by the relaxation time of the engine. The maximal work and the Carnot efficiency are...