当前位置:网站首页>Resolving C# non-static field, method or property "islandnum.Program.getIslandCount(int[][], int, int)" requires an object reference
Resolving C# non-static field, method or property "islandnum.Program.getIslandCount(int[][], int, int)" requires an object reference
2022-08-02 07:23:00 【xqlily】
Run a piece of code for a two-dimensional array in c#:
When the following code is called in the main function main
getIslandCount(map, row, col);Error in error title:
A non-static field, method or property 'islandnum.Program.getIslandCount(int[][], int, int)' requires an object reference
Before the main function, this function is defined as follows:
public int getIslandCount(int[][] map, int row, int col)Then just change the above line of code to:
public static int getIslandCount(int[][] map, int row, int col)The error is solved, just add a static.
边栏推荐
- A detailed introduction to the deployment and usage of the Nacos registry
- Toolbox App 1.25 New Features at a Glance | Version Update
- 看图就懂|衡量业务增长健康的销售指标如何选择
- SphereEx苗立尧:云原生架构下的Database Mesh研发实践
- MySQL高级语句(一)
- nacos源码启动找不到istio包
- Two good php debug tutorials
- PHP Warning: putenv() has been disabled for security reasons in phar
- .NET Static Code Weaving - Rougamo Release 1.1.0
- MySQL (3)
猜你喜欢

Nodejs安装教程

Launch Space on-premises deployment (local) Beta!

数据库概论-MySQL的数据表的基本操作
![[Dataset][VOC] Male and female dataset voc format 6188 sheets](/img/72/d3e46a820796a48b458cd2d0a18f8f.png)
[Dataset][VOC] Male and female dataset voc format 6188 sheets

MySQL (3)

MySQL union query (multi-table query)

rhce homework

awk语法-01-基础语法(命令、选项、内部变量)

【npm install 报错问题合集】- npm ERR! code ENOTEMPTY npm ERR! syscall rmdir

aTrust项目的相关操作与分享
随机推荐
C# FileInfo class
Vscode连接远程服务器出现‘Acquiring lock on/home/~’问题
MySQL Advanced Statements (1)
Mining game (C language)
MySql - there is no insert, there is update or ignored
PMP新考纲考试内容介绍
[npm install error report collection] - npm ERR! code ENOTEMPTY npm ERR! syscall rmdir
项目开发规范
MySql 5.7.38下载安装教程 ,并实现在Navicat操作MySql
node安装及环境变量配置
GCC编译器技术解析
Py's mlxtend: a detailed guide to the introduction, installation, and usage of the mlxtend library
Toolbox App 1.25 New Features at a Glance | Version Update
Analysis of port 9848 error at startup of Nacos client (non-version upgrade problem)
BGP+MPLS Comprehensive Experiment
Dataset: A detailed guide to the download link collection of commonly used datasets in machine learning
July 18-July 31, 2022 (Ue4 video tutorials and documentation, 20 hours. Total 1412 hours, 8588 hours left)
A detailed introduction to the deployment and usage of the Nacos registry
CAT1 4G+Ethernet development board Tencent cloud mobile phone WeChat applet display temperature and delivery control
Servlet