#include <iostream> // Dalam ni ada semua function dan file untuk input output C++
//Wajib include ^
// semua karakter selepas '//' adalah comment, tak kisah kat mana
// ini jugak comment
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#This file contains example code of diffie hellman key exhange demo | |
#This is slow for actual usage, this for demo purposes only | |
def clamp(x, min, max): | |
if x <= min: | |
return min | |
elif x >= max: | |
return max | |
return x |