blob: 773fa7aa9f956385ea20e055275b481adec8b4a4 [file] [log] [blame]
Kevin O'Connor38cadac2009-05-13 20:55:31 -04001#!/usr/bin/env python
2# Script to report the checksum of a file.
3#
4# Copyright (C) 2009 Kevin O'Connor <kevin@koconnor.net>
5#
6# This file may be distributed under the terms of the GNU GPLv3 license.
7
8import sys
9
10def main():
11 data = sys.stdin.read()
12 ords = map(ord, data)
Johannes Krampf064fd062014-01-12 11:14:54 -050013 print("sum=%x\n" % sum(ords))
Kevin O'Connor38cadac2009-05-13 20:55:31 -040014
15if __name__ == '__main__':
16 main()