当前位置: 首页 > news >正文

网站内链是什么seo优化一般包括哪些

网站内链是什么,seo优化一般包括哪些,企业网站代码,网站建设与管理方案的总结解题思路 由于最后返回一个01字符串表示所选人的状态要求人数最少,即字符串长度最少而要用最少的字符,找出则返回的字符为二进制下的编号这样利用了所有的01字符号人表示二进制下位的情况注意对于2的次方项,只需要有位,可以用位均…

解题思路

  • 由于最后返回一个01字符串表示所选人的状态
  • 要求人数最少,即字符串长度最少
  • 而要用最少的字符,找出Bad\ juice
  • 则返回的字符为二进制下Bad\ juice的编号
  • 这样利用了所有的01字符
  • i号人表示二进制下i位的情况
  • 注意对于2的次方项n=2^k,只需要有k-1位,n可以用k-1位均为0表示
import java.io.*;
import java.math.BigInteger;
import java.util.Arrays;
import java.util.BitSet;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.Map;
import java.util.Objects;
import java.util.PriorityQueue;
import java.util.Queue;
import java.util.Random;
import java.util.Scanner;
import java.util.Stack;
import java.util.StringTokenizer;
import java.util.Vector;public class Main{static long md=(long)998244353;static long Linf=Long.MAX_VALUE/2;static int inf=Integer.MAX_VALUE/2;static class Node{int x;int y;public Node(int u,int v) {x=u;y=v;}}public static void main(String[] args) throws IOException{
//		AReader input=new AReader();
//	    PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));	Scanner input=new Scanner(System.in);int n=input.nextInt();//返回的二进制字符串即为变质的编号int t=0;while((1<<t)<n)t++;System.out.println(t);int[] c=new int[n+1];for(int i=0;i<t;++i) {for(int j=1;j<=n;++j) {if(((j>>i)&1)==1)c[i]++;}}for(int i=0;i<t;++i) {System.out.print(c[i]);for(int j=1;j<=n;++j) {if(((j>>i)&1)==1)System.out.print(" "+j);}System.out.println();}String string=input.next();char[] s=string.toCharArray();int ans=0;for(int i=0;i<t;++i) {if(s[i]=='1')ans|=(1<<i);}if(ans==0)ans=n;System.out.println(ans);System.out.flush();
// 	    out.flush();
//	    out.close();}//System.out.println();//out.println();staticclass AReader{ BufferedReader bf;StringTokenizer st;BufferedWriter bw;public AReader(){bf=new BufferedReader(new InputStreamReader(System.in));st=new StringTokenizer("");bw=new BufferedWriter(new OutputStreamWriter(System.out));}public String nextLine() throws IOException{return bf.readLine();}public String next() throws IOException{while(!st.hasMoreTokens()){st=new StringTokenizer(bf.readLine());}return st.nextToken();}public char nextChar() throws IOException{//确定下一个token只有一个字符的时候再用return next().charAt(0);}public int nextInt() throws IOException{return Integer.parseInt(next());}public long nextLong() throws IOException{return Long.parseLong(next());}public double nextDouble() throws IOException{return Double.parseDouble(next());}public float nextFloat() throws IOException{return Float.parseFloat(next());}public byte nextByte() throws IOException{return Byte.parseByte(next());}public short nextShort() throws IOException{return Short.parseShort(next());}public BigInteger nextBigInteger() throws IOException{return new BigInteger(next());}public void println() throws IOException {bw.newLine();}public void println(int[] arr) throws IOException{for (int value : arr) {bw.write(value + " ");}println();}public void println(int l, int r, int[] arr) throws IOException{for (int i = l; i <= r; i ++) {bw.write(arr[i] + " ");}println();}public void println(int a) throws IOException{bw.write(String.valueOf(a));bw.newLine();}public void print(int a) throws IOException{bw.write(String.valueOf(a));}public void println(String a) throws IOException{bw.write(a);bw.newLine();}public void print(String a) throws IOException{bw.write(a);}public void println(long a) throws IOException{bw.write(String.valueOf(a));bw.newLine();}public void print(long a) throws IOException{bw.write(String.valueOf(a));}public void println(double a) throws IOException{bw.write(String.valueOf(a));bw.newLine();}public void print(double a) throws IOException{bw.write(String.valueOf(a));}public void print(char a) throws IOException{bw.write(String.valueOf(a));}public void println(char a) throws IOException{bw.write(String.valueOf(a));bw.newLine();}}
}

 

http://www.hkea.cn/news/576807/

相关文章:

  • 免费网站建站工具购买域名的网站
  • 淘宝联盟怎么做网站百度网站提交
  • 前端做用vue做后台多还是做网站多青岛网站快速排名优化
  • 岳阳网站开发公司海淀区seo多少钱
  • 2017年做网站维护总结百度搜索软件
  • 南京网站建设公司点击器原理
  • 网站怎么编辑搜狗网站提交入口
  • 自建网站做外贸的流程广告推广方式
  • 警告欺骗网站模板免费注册
  • 获取网站访客信息seo分析师招聘
  • 制作网页的网站有哪些网站建设
  • 日本真人做爰无遮挡视频免费网站嘉兴关键词优化报价
  • 忻州市中小企业局网站贵州整站优化seo平台
  • 网页怎么制作超链接seo兼职接单平台
  • 网站建设中应注意哪些问题重庆整站seo
  • 贵阳网站建设哪家便宜微商软文范例大全100
  • 怎么在微信上做网站竞价交易
  • wordpress优化版4.7.4网站seo设计
  • 网上课程网站精准客户数据采集软件
  • 专业网站建设报价外呼系统电销
  • 网站建设公司价格差别seo还有哪些方面的优化
  • 哪家公司建造了迪士尼乐园关键词优化推广排名多少钱
  • 做教育的网站有哪些内容吗湖南网站营销推广
  • wordpress 跳过ftp搜索引擎排名优化方案
  • 360做的网站北京营销推广公司
  • 我国政府网站建设的趋势宁波seo公司排名榜
  • 高端网站建设,恩愉科技专业的seo搜索引擎优化培训
  • 跨境网站开发公司网站seo思路
  • 冠县网站建设活动推广方案
  • 鲜花培训网站建设网站推广要点