예제 #1
0
    public void imp()
    {
        no x = ini;

        while (x != null)
        {
            System.out.println(x.dado);
            x = x.prox;
        }
    }
예제 #2
0
파일: p3.cs 프로젝트: karunasagark/ps
        public void foo()
        {
            int n = int.Parse(Console.ReadLine());

            no[] l = new no[n];
            for (int i = 0; i < n; i++)
            {
                string[] sp = Console.ReadLine().Split(' ');
                no o = new no();
                o.v = i; o.d = int.Parse(sp[0]); o.x = int.Parse(sp[1]);
                l[i] = o;
            }

            List<string> ed = new List<string>();
            while (l.Length > 0)
            {
                Array.Sort(l, delegate(no a, no b){
                    return a.d.CompareTo(b.d);
                });

                no u = l[0];
                no[] ll = new no[l.Length - 1];
                for (int i = 1; i < l.Length; i++)
                {
                    ll[i - 1] = l[i];
                }
                l = ll;

                if (u.d == 0)
                {
                    continue;
                }
                if (u.d == 1)
                {
                    ed.Add(u.v + " " + u.x);
                    for (int i = 0; i < l.Length; i++)
                    {
                        if (l[i].v != u.x)
                            continue;
                        l[i].d--;
                        l[i].x = l[i].x ^ u.v;
                        break;
                    }
                }
            }

            Console.WriteLine(ed.Count);
            for (int i = 0; i < ed.Count; i++)
            {
                Console.WriteLine(ed[i]);
            }
        }
예제 #3
0
    public void remover(int num)
    {
        no ant   = null;
        no atual = ini;

        while (atual != null)
        {
            if (atual.dado == num)
            {
                ant.prox = atual.prox;
            }
            ant   = atual;
            atual = atual.prox;
        }
    }
예제 #4
0
    public void inserir(int num)
    {
        no novo = new no();

        novo.dado = num;
        novo.prox = null;
        if (ini == null)
        {
            ini = novo;
        }
        else
        {
            fim.prox = novo;
        }
        fim = novo;
    }
예제 #5
0
https://github.com/NLog/NLog/wiki/WebService-target---Workaround-for-url-variables
**If you want to update it on the fly (no new Deployment).**
예제 #6
0
 public void AddNo(no hamno2)
 {
     onno += hamno2;
 }
예제 #7
0
 public void InitTWBoard()
 {
     onyes += yes_;
     onno  += no_;
     Show();
 }
예제 #8
0
 Compensation(no pre - existing heatingcontrols) Compensation_[walltype] _nopreHCs
예제 #9
0
 Smartthermostat(no pre - existing programmerand roomthermostat)   Smarttherm_[walltype] _nopreP & RT
This solution works and could be simplified if you only have flat (no custom class properties) of the class you are trying to deserialize. Or, it could be extended to support custom class properties. The solution could also be made into a base type that your other classes derive from, and you'd do `GetType()` in `DeserializableProperties` instead of `typeof(Language)`. It is an overly verbose solution, but until `YamlDotNet` has a cleaner/simpler/proper solution, this was the best I could come up with after exploring their source code.
예제 #11
0
		void RaiseSearchResult (no.dctapps.commons.events.model.Lager find)
		{
			Console.WriteLine ("foo");
			//TOD implement me
		}