using System;
namespace Articulos.Preguntas
{
public class UsoThisEnClase
{
private int campo;
public UsoThisEnClase(int valor)
{
this.campo = valor;
}
public void Metodo(int a)
{
this.campo = a;
this = new UsoThisEnClase(9);
Console.WriteLine(campo.ToString());
}
public static void Main()
{
UsoThisEnClase ut = new UsoThisEnClase(3);
ut.Metodo(4);
}
}
}
dXNpbmcgU3lzdGVtOwoKbmFtZXNwYWNlIEFydGljdWxvcy5QcmVndW50YXMKewogICAgcHVibGljIGNsYXNzIFVzb1RoaXNFbkNsYXNlCiAgICB7CiAgICAgICAgcHJpdmF0ZSBpbnQgY2FtcG87CiAgICAgICAgCiAgICAgICAgcHVibGljIFVzb1RoaXNFbkNsYXNlKGludCB2YWxvcikKICAgICAgICB7CiAgICAgICAgICAgIHRoaXMuY2FtcG8gPSB2YWxvcjsKICAgICAgICB9CiAgICAgICAgCiAgICAgICAgcHVibGljIHZvaWQgTWV0b2RvKGludCBhKQogICAgICAgIHsKICAgICAgICAgICAgdGhpcy5jYW1wbyA9IGE7CiAgICAgICAgICAgIAogICAgICAgICAgICB0aGlzID0gbmV3IFVzb1RoaXNFbkNsYXNlKDkpOwogICAgICAgICAgICAKICAgICAgICAgICAgQ29uc29sZS5Xcml0ZUxpbmUoY2FtcG8uVG9TdHJpbmcoKSk7CiAgICAgICAgfQogICAgICAgIAogICAgICAgIHB1YmxpYyBzdGF0aWMgdm9pZCBNYWluKCkKICAgICAgICB7CiAgICAgICAgICAgIFVzb1RoaXNFbkNsYXNlIHV0ID0gbmV3IFVzb1RoaXNFbkNsYXNlKDMpOwogICAgICAgICAgICAKICAgICAgICAgICAgdXQuTWV0b2RvKDQpOwogICAgICAgIH0KICAgIH0KfQ==