Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void main() {
- var c = Modder();
- print(c.modfunc<int>(10,5));
- }
- class Modder
- {
- Modder();
- T modfunc<T extends num>(T a,T b)
- {
- return (a%b) as T;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement