We report on a "source-sink" algorithm which allows one to calculate time-resolved physical quantities from a general nanoelectronic quantum system (described by an arbitrary time-dependent quadratic Hamiltonian) connected to infinite electrodes. Although mathematically equivalent to the non equilibrium Green's function formalism, the approach is based on the scattering wave functions of the system. It amounts to solving a set of generalized Schrödinger equations which include an additional "source" term (coming from the time dependent perturbation) and an absorbing "sink" term (the electrodes). The algorithm execution time scales linearly with both system size and simulation time allowing one to simulate large systems (currently around 10 6 degrees of freedom) and/or large times (currently around 10 5 times the smallest time scale of the system). As an application we calculate the current-voltage characteristics of a Josephson junction for both short and long junctions, and recover the multiple Andreev reflexion (MAR) physics. We also discuss two intrinsically time-dependent situations: the relaxation time of a Josephson junction after a quench of the voltage bias, and the propagation of voltage pulses through a Josephson junction. In the case of a ballistic, long Josephson junction, we predict that a fast voltage pulse creates an oscillatory current whose frequency is controlled by the Thouless energy of the normal part. A similar effect is found for short junctions; a voltage pulse produces an oscillating current which, in the absence of electromagnetic environment, does not relax.As quantum nanoelectronics experiments get faster (in the GHz range and above) it becomes possible to study the time dependent dynamics of devices in their quantum regimes, i.e. at frequencies higher than the system temperature (1K corresponds roughly to 20GHz). Recent achievements include coherent single electron sources with well defined release time 1 or energy 2 , pulse propagation along quantum Hall edge states 3-5 and terahertz measurements in carbon nanotubes 6 . While the mathematical framework for describing quantum transport in the time domain has been around since the 90s 7,8 , the corresponding non-equilibrium Green's function formalism (NEGF) is rather cumbersome and can only be solved in rather simple situations, even with the help of numerics. In Ref. 9 we developed an alternative formulation of the theory which is much easier to solve numerically, in addition to being more physically transparent. The approach of Ref. 9 (to which we refer for further references) was recently used in a variety of situations including electronic interferometers 10,11 , quantum Hall effect 12 , normal-superconducting junctions 13 , Floquet topological insulators 14 and the calculation of the quantum noise of voltage pulses 15 .The best algorithm introduced in Ref. 9 (nicknamed WF-C) has a computational execution time that scales linearly with the system size N , but as the square of the total simulation time. While for ballistic systems ...