view src/testdir/test_channel_write.py @ 35067:b2e515aab168 default tip

runtime(doc): CI: remove trailing white space in documentation Commit: https://github.com/vim/vim/commit/11250510404860a76d9e9cea4f99025277f607a5 Author: Christian Brabandt <cb@256bit.org> Date: Sat Apr 27 12:01:15 2024 +0200 runtime(doc): CI: remove trailing white space in documentation Signed-off-by: Christian Brabandt <cb@256bit.org>
author Christian Brabandt <cb@256bit.org>
date Sat, 27 Apr 2024 12:15:02 +0200
parents 5cd9ba96561d
children
line wrap: on
line source

#!/usr/bin/python
#
# Program that writes a number to stdout repeatedly
#
# This requires Python 2.6 or later.

from __future__ import print_function
import sys
import time

if __name__ == "__main__":

    done = 0
    while done < 10:
        done = done + 1
        print(done)
        sys.stdout.flush()
        time.sleep(0.05)  # sleep 50 msec