by Sang Nguyễn Kim
Version 1 (June 22, 2025)
Download (4 downloads)
15 blocks
diff_ms := target_time - now
total_seconds := diff_ms / 1000
total_minutes := total_seconds / 60
total_hours := total_minutes / 60
total_days := total_hours / 24
5. Expression – Tách ra năm / tháng / ngày
years := total_days / 365
remaining_days := total_days % 365
months := remaining_days / 30
days := remaining_days % 30
6. Expression – Tính giờ / phút / giây còn lại
remaining_hours := total_hours % 24
remaining_minutes := total_minutes % 60
remaining_seconds := total_seconds % 60
7. Expression – Ghép kết quả
result := "Còn ${years} năm ${months} tháng ${days} ngày ${remaining_hours} giờ ${remaining_minutes} phút ${remaining_seconds} giây"