Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.javarush.task.task02.task0204;
- public class Solution {
- public static void main(String[] args) {
- Man man=new Man();
- Woman woman=new Woman();
- man.wife=woman;
- woman.husband=man;
- }
- public static class Man {
- public int age;
- public int height;
- public Woman wife;
- }
- public static class Woman {
- public int age;
- public int height;
- public Man husband;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement