SlideShare une entreprise Scribd logo
1  sur  34
Télécharger pour lire hors ligne
+ sprinkles of




    
    
public void castSpell(Spell spell, bool repeat,
            int timeOutinMs, int rangeInM, bool hitFriendly) {…}

public void castSafeSpell(Spell spell, bool repeat,
            int timeOutinMs, int rangeInM)
        {
            castSpell(spell, repeat, timeOutinMs, range, false);
        }

public void castNeverEndingSpell(Spell spell,
            int rangeInM, bool hitFriendly)
        {
            castSpell(spell, true, -1, range, hitFriendly);
        }
public void castSpell(Spell spell, bool repeat = false,
            int timeOutinMs = -1, int rangeInM = 30,
            bool hitFriendly = false)




Spell frost = new FrostFury();
castSpell(frost);


 Spell frost = new FrostFury();
castSpell(frost, false);
public void castSpell(Spell spell, bool repeat = false,
           int timeOutinMs = -1, int rangeInM = 30,
           bool hitFriendly = false)




Spell frost = new FrostFury();
castSpell(frost, rangeInM: 1000);








    

    
    

    

        List<object> names = new List<string>();
HordeSubject



Orc      Undead      Troll
HordeSubject player = new Orc();


HordeSubject player = new Undead();




List<HordeSubject> raid = new List<Orc>();



           ℤ

    
       ℤ
    

         ∈ℤ
       
       
       
       ∈ℤ

    
        ∀    ∈ℤ
    

    

    
       ∀    ∈ℤ
        ∀    ∈ℤ
    

    

    
       ∀    ∈ℤ
                  ∀   ∈ℤ
    
Orc   HordeSubject
Undead   HordeSubject   OrcShaman   Orc

Orc   HordeSubject
       Orc           HordeSubject

               
Orc   HordeSubject
      Orc                 HordeSubject
List<HordeSubject> raid =
     new List<Orc>();


raid.Add(new Undead());
IEnumerable<HordeSubject> raid =
     new List<Orc>();


                                  out
    public interface IEnumerable<out T>
       {
           IEnumerator<T> GetEnumerator();
       }

    public interface IEnumerator<out T>
       {
           T Current { get; }
           bool MoveNext();
       }
IComparer<HordeSubject> hordeStat =
     GetHordeComparer();
IComparer<Orc> orcStat = hordeStat;



                                       in

    public interface IComparer<in T>
        {
            int Compare(T x, T y);
        }
   
    

   


   

    

    

    

    

    







    
    

    

    

    

    

    

    

    
    

Contenu connexe

Tendances

Data structure programs in c++
Data structure programs in c++Data structure programs in c++
Data structure programs in c++mmirfan
 
Fertile Ground: The Roots of Clojure
Fertile Ground: The Roots of ClojureFertile Ground: The Roots of Clojure
Fertile Ground: The Roots of ClojureMike Fogus
 
Bytes in the Machine: Inside the CPython interpreter
Bytes in the Machine: Inside the CPython interpreterBytes in the Machine: Inside the CPython interpreter
Bytes in the Machine: Inside the CPython interpreterakaptur
 
"A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!...
"A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!..."A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!...
"A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!...akaptur
 
Cilk Plus Parallel Reduction
Cilk Plus Parallel ReductionCilk Plus Parallel Reduction
Cilk Plus Parallel ReductionAlbert DeFusco
 
An Introduction to Tinkerpop
An Introduction to TinkerpopAn Introduction to Tinkerpop
An Introduction to TinkerpopTakahiro Inoue
 
20110424 action scriptを使わないflash勉強会
20110424 action scriptを使わないflash勉強会20110424 action scriptを使わないflash勉強会
20110424 action scriptを使わないflash勉強会Hiroki Mizuno
 
PFDS 8.4.1
PFDS 8.4.1PFDS 8.4.1
PFDS 8.4.1rf0444
 
All I know about rsc.io/c2go
All I know about rsc.io/c2goAll I know about rsc.io/c2go
All I know about rsc.io/c2goMoriyoshi Koizumi
 
Python opcodes
Python opcodesPython opcodes
Python opcodesalexgolec
 
TypeScript Introduction
TypeScript IntroductionTypeScript Introduction
TypeScript IntroductionHans Höchtl
 
Code as data as code.
Code as data as code.Code as data as code.
Code as data as code.Mike Fogus
 
bpftrace - Tracing Summit 2018
bpftrace - Tracing Summit 2018bpftrace - Tracing Summit 2018
bpftrace - Tracing Summit 2018AlastairRobertson9
 

Tendances (20)

Data structure programs in c++
Data structure programs in c++Data structure programs in c++
Data structure programs in c++
 
Fertile Ground: The Roots of Clojure
Fertile Ground: The Roots of ClojureFertile Ground: The Roots of Clojure
Fertile Ground: The Roots of Clojure
 
Vcs16
Vcs16Vcs16
Vcs16
 
Bytes in the Machine: Inside the CPython interpreter
Bytes in the Machine: Inside the CPython interpreterBytes in the Machine: Inside the CPython interpreter
Bytes in the Machine: Inside the CPython interpreter
 
"A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!...
"A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!..."A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!...
"A 1,500 line (!!) switch statement powers your Python!" - Allison Kaptur, !!...
 
Cilk Plus Parallel Reduction
Cilk Plus Parallel ReductionCilk Plus Parallel Reduction
Cilk Plus Parallel Reduction
 
Software Exploits
Software ExploitsSoftware Exploits
Software Exploits
 
An Introduction to Tinkerpop
An Introduction to TinkerpopAn Introduction to Tinkerpop
An Introduction to Tinkerpop
 
20110424 action scriptを使わないflash勉強会
20110424 action scriptを使わないflash勉強会20110424 action scriptを使わないflash勉強会
20110424 action scriptを使わないflash勉強会
 
Python 5-迴圈-while
Python 5-迴圈-whilePython 5-迴圈-while
Python 5-迴圈-while
 
Snake.c
Snake.cSnake.c
Snake.c
 
Python 4-迴圈-for
Python 4-迴圈-forPython 4-迴圈-for
Python 4-迴圈-for
 
PFDS 8.4.1
PFDS 8.4.1PFDS 8.4.1
PFDS 8.4.1
 
All I know about rsc.io/c2go
All I know about rsc.io/c2goAll I know about rsc.io/c2go
All I know about rsc.io/c2go
 
Python opcodes
Python opcodesPython opcodes
Python opcodes
 
JavaScript @ CTK
JavaScript @ CTKJavaScript @ CTK
JavaScript @ CTK
 
TypeScript Introduction
TypeScript IntroductionTypeScript Introduction
TypeScript Introduction
 
Code as data as code.
Code as data as code.Code as data as code.
Code as data as code.
 
bpftrace - Tracing Summit 2018
bpftrace - Tracing Summit 2018bpftrace - Tracing Summit 2018
bpftrace - Tracing Summit 2018
 
Es6 hackathon
Es6 hackathonEs6 hackathon
Es6 hackathon
 

Similaire à Casting spells and polymorphism in C

20070329 Java Programing Tips
20070329 Java Programing Tips20070329 Java Programing Tips
20070329 Java Programing TipsShingo Furuyama
 
Java 8 - Nuts and Bold - SFEIR Benelux
Java 8 - Nuts and Bold - SFEIR BeneluxJava 8 - Nuts and Bold - SFEIR Benelux
Java 8 - Nuts and Bold - SFEIR Beneluxyohanbeschi
 
GameOfLife.cs using System; using System.Collections.Generic;.pdf
GameOfLife.cs using System; using System.Collections.Generic;.pdfGameOfLife.cs using System; using System.Collections.Generic;.pdf
GameOfLife.cs using System; using System.Collections.Generic;.pdfaravlitraders2012
 
import java.util.Scanner;public class Main {    public static in.pdf
import java.util.Scanner;public class Main {    public static in.pdfimport java.util.Scanner;public class Main {    public static in.pdf
import java.util.Scanner;public class Main {    public static in.pdfanwarsadath111
 
LINQ Internals - STLDODN
LINQ Internals - STLDODNLINQ Internals - STLDODN
LINQ Internals - STLDODNKeith Dahlby
 
Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01
Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01
Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01google
 
Apache PIG - User Defined Functions
Apache PIG - User Defined FunctionsApache PIG - User Defined Functions
Apache PIG - User Defined FunctionsChristoph Bauer
 
Java binary subtraction
Java binary subtractionJava binary subtraction
Java binary subtractionCharm Sasi
 
Java, Up to Date Sources
Java, Up to Date SourcesJava, Up to Date Sources
Java, Up to Date Sources輝 子安
 
Are we ready to Go?
Are we ready to Go?Are we ready to Go?
Are we ready to Go?Adam Dudczak
 
5 c control statements looping
5  c control statements looping5  c control statements looping
5 c control statements loopingMomenMostafa
 

Similaire à Casting spells and polymorphism in C (13)

20070329 Java Programing Tips
20070329 Java Programing Tips20070329 Java Programing Tips
20070329 Java Programing Tips
 
Java 8 - Nuts and Bold - SFEIR Benelux
Java 8 - Nuts and Bold - SFEIR BeneluxJava 8 - Nuts and Bold - SFEIR Benelux
Java 8 - Nuts and Bold - SFEIR Benelux
 
GameOfLife.cs using System; using System.Collections.Generic;.pdf
GameOfLife.cs using System; using System.Collections.Generic;.pdfGameOfLife.cs using System; using System.Collections.Generic;.pdf
GameOfLife.cs using System; using System.Collections.Generic;.pdf
 
import java.util.Scanner;public class Main {    public static in.pdf
import java.util.Scanner;public class Main {    public static in.pdfimport java.util.Scanner;public class Main {    public static in.pdf
import java.util.Scanner;public class Main {    public static in.pdf
 
LINQ Internals - STLDODN
LINQ Internals - STLDODNLINQ Internals - STLDODN
LINQ Internals - STLDODN
 
Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01
Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01
Kdahlby 200908 Stldodn Linqinternals 090903222505 Phpapp01
 
Apache PIG - User Defined Functions
Apache PIG - User Defined FunctionsApache PIG - User Defined Functions
Apache PIG - User Defined Functions
 
The Art of Clean Code
The Art of Clean CodeThe Art of Clean Code
The Art of Clean Code
 
Java binary subtraction
Java binary subtractionJava binary subtraction
Java binary subtraction
 
Java, Up to Date Sources
Java, Up to Date SourcesJava, Up to Date Sources
Java, Up to Date Sources
 
Are we ready to Go?
Are we ready to Go?Are we ready to Go?
Are we ready to Go?
 
PRACTICAL COMPUTING
PRACTICAL COMPUTINGPRACTICAL COMPUTING
PRACTICAL COMPUTING
 
5 c control statements looping
5  c control statements looping5  c control statements looping
5 c control statements looping
 

Plus de Mustafa Isik

SumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-Simulationsdaten
SumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-SimulationsdatenSumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-Simulationsdaten
SumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-SimulationsdatenMustafa Isik
 
Game Development: The Golden Age of Indie
Game Development: The Golden Age of IndieGame Development: The Golden Age of Indie
Game Development: The Golden Age of IndieMustafa Isik
 
Indie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurbo
Indie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurboIndie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurbo
Indie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurboMustafa Isik
 
Ein Rechner, ein Chip: MOS Technology 6502
Ein Rechner, ein Chip: MOS Technology 6502Ein Rechner, ein Chip: MOS Technology 6502
Ein Rechner, ein Chip: MOS Technology 6502Mustafa Isik
 
Tanning for Open Source Projects - The Google Summer of Code & You
Tanning for Open Source Projects - The Google Summer of Code & YouTanning for Open Source Projects - The Google Summer of Code & You
Tanning for Open Source Projects - The Google Summer of Code & YouMustafa Isik
 
ISTNW Alpha at GTUG Munich
ISTNW Alpha at GTUG MunichISTNW Alpha at GTUG Munich
ISTNW Alpha at GTUG MunichMustafa Isik
 
Anybody can be a great mentor ... maybe
Anybody can be a great mentor ... maybeAnybody can be a great mentor ... maybe
Anybody can be a great mentor ... maybeMustafa Isik
 
Cloud Computing Is Not Cotton Candy ... Or Is It?
Cloud Computing Is Not Cotton Candy ... Or Is It?Cloud Computing Is Not Cotton Candy ... Or Is It?
Cloud Computing Is Not Cotton Candy ... Or Is It?Mustafa Isik
 
Modeling Scenarios with Sequence Diagrams
Modeling Scenarios with Sequence DiagramsModeling Scenarios with Sequence Diagrams
Modeling Scenarios with Sequence DiagramsMustafa Isik
 
Striding towards the Future Multiple Edits at a Time
Striding towards the Future Multiple Edits at a TimeStriding towards the Future Multiple Edits at a Time
Striding towards the Future Multiple Edits at a TimeMustafa Isik
 
Wiring Hacker Synapses - Cola: Real-Time Shared Editing
Wiring Hacker Synapses - Cola: Real-Time Shared EditingWiring Hacker Synapses - Cola: Real-Time Shared Editing
Wiring Hacker Synapses - Cola: Real-Time Shared EditingMustafa Isik
 

Plus de Mustafa Isik (11)

SumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-Simulationsdaten
SumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-SimulationsdatenSumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-Simulationsdaten
SumoViz v1.0: HTML5-basierte Visualisierung von Fußgänger-Simulationsdaten
 
Game Development: The Golden Age of Indie
Game Development: The Golden Age of IndieGame Development: The Golden Age of Indie
Game Development: The Golden Age of Indie
 
Indie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurbo
Indie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurboIndie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurbo
Indie, Indie, Überall: Erfahrungen aus einem Jahr SuperHyperTurbo
 
Ein Rechner, ein Chip: MOS Technology 6502
Ein Rechner, ein Chip: MOS Technology 6502Ein Rechner, ein Chip: MOS Technology 6502
Ein Rechner, ein Chip: MOS Technology 6502
 
Tanning for Open Source Projects - The Google Summer of Code & You
Tanning for Open Source Projects - The Google Summer of Code & YouTanning for Open Source Projects - The Google Summer of Code & You
Tanning for Open Source Projects - The Google Summer of Code & You
 
ISTNW Alpha at GTUG Munich
ISTNW Alpha at GTUG MunichISTNW Alpha at GTUG Munich
ISTNW Alpha at GTUG Munich
 
Anybody can be a great mentor ... maybe
Anybody can be a great mentor ... maybeAnybody can be a great mentor ... maybe
Anybody can be a great mentor ... maybe
 
Cloud Computing Is Not Cotton Candy ... Or Is It?
Cloud Computing Is Not Cotton Candy ... Or Is It?Cloud Computing Is Not Cotton Candy ... Or Is It?
Cloud Computing Is Not Cotton Candy ... Or Is It?
 
Modeling Scenarios with Sequence Diagrams
Modeling Scenarios with Sequence DiagramsModeling Scenarios with Sequence Diagrams
Modeling Scenarios with Sequence Diagrams
 
Striding towards the Future Multiple Edits at a Time
Striding towards the Future Multiple Edits at a TimeStriding towards the Future Multiple Edits at a Time
Striding towards the Future Multiple Edits at a Time
 
Wiring Hacker Synapses - Cola: Real-Time Shared Editing
Wiring Hacker Synapses - Cola: Real-Time Shared EditingWiring Hacker Synapses - Cola: Real-Time Shared Editing
Wiring Hacker Synapses - Cola: Real-Time Shared Editing
 

Dernier

Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 

Dernier (20)

Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 

Casting spells and polymorphism in C

  • 2.
  • 3.     
  • 4. public void castSpell(Spell spell, bool repeat, int timeOutinMs, int rangeInM, bool hitFriendly) {…} public void castSafeSpell(Spell spell, bool repeat, int timeOutinMs, int rangeInM) { castSpell(spell, repeat, timeOutinMs, range, false); } public void castNeverEndingSpell(Spell spell, int rangeInM, bool hitFriendly) { castSpell(spell, true, -1, range, hitFriendly); }
  • 5. public void castSpell(Spell spell, bool repeat = false, int timeOutinMs = -1, int rangeInM = 30, bool hitFriendly = false) Spell frost = new FrostFury(); castSpell(frost); Spell frost = new FrostFury(); castSpell(frost, false);
  • 6. public void castSpell(Spell spell, bool repeat = false, int timeOutinMs = -1, int rangeInM = 30, bool hitFriendly = false)  Spell frost = new FrostFury(); castSpell(frost, rangeInM: 1000);  
  • 7.       List<object> names = new List<string>();
  • 8. HordeSubject Orc Undead Troll
  • 9. HordeSubject player = new Orc(); HordeSubject player = new Undead(); List<HordeSubject> raid = new List<Orc>();
  • 10.
  • 11.
  • 12.    ℤ   ℤ 
  • 13. ∈ℤ        ∈ℤ    ∀ ∈ℤ  
  • 14.   ∀ ∈ℤ  ∀ ∈ℤ      ∀ ∈ℤ  ∀ ∈ℤ 
  • 15.
  • 16.
  • 17.
  • 18. Orc HordeSubject Undead HordeSubject OrcShaman Orc
  • 19.
  • 20.  Orc HordeSubject Orc HordeSubject  Orc HordeSubject Orc HordeSubject
  • 21. List<HordeSubject> raid = new List<Orc>(); raid.Add(new Undead());
  • 23.   out public interface IEnumerable<out T> { IEnumerator<T> GetEnumerator(); } public interface IEnumerator<out T> { T Current { get; } bool MoveNext(); }
  • 24. IComparer<HordeSubject> hordeStat = GetHordeComparer(); IComparer<Orc> orcStat = hordeStat;
  • 25.   in public interface IComparer<in T> { int Compare(T x, T y); }
  • 26.
  • 27.
  • 28.         
  • 29.
  • 30.     
  • 32.
  • 33.          
  • 34.      