up to pseudocode everything is fine