import sys

from PyQt5.QtCore import *

from PyQt5.QtGui import *

from PyQt5.QtWidgets import *

from threading import Timer

import time



class ii(QWidget):

    

    def __init__ (self):

        super().__init__()

        self.year = QLCDNumber(self)

        self.month = QLCDNumber(self)

        self.day = QLCDNumber(self)

        self.hour = QLCDNumber(self)

        self.min = QLCDNumber(self)

        self.sec = QLCDNumber(self)

        

        self.ininin()

        

        

    def ininin(self):

        

        box = QHBoxLayout()

        box.addWidget(self.year)

        box.addWidget(self.month)

        box.addWidget(self.day)

        

        box2 = QHBoxLayout()

        box2.addWidget(self.hour)

        box2.addWidget(self.min)

        box2.addWidget(self.sec)

        

        vbox = QVBoxLayout()

        vbox.addLayout(box)

        vbox.addLayout(box2)

        

        self.setLayout(vbox)

        self.setWindowTitle('시계')

        self.setGeometry(200,200, 400, 200)  

 

        self.aa()

        

    def aa(self):

        

        

        t.time.time()

        

        kor = time.localtime(t)


        self.year.display(kor.tm_year)

        self.month.display(kor.tm_mon)

        self.day.display(kor.tm_mday)

        self.hour.display(kor.tm_hour)

        self.min.display(kor.tm_min)

        self.sec.display(kor.tm_sec)

        

        timer = Timer(1, self.aa)

        timer.start()


if __name__ == '__main__':

     

    app = QApplication(sys.argv)

    w = ii()

    w.show()    

    sys.exit(app.exec_())





NameError: name 't' is not defined

이 지랄 하는데 뭐냐?